NickServ GETEMAIL + ChanServ SET RESTRICTED
All checks were successful
CI / check (push) Successful in 3m51s

GETEMAIL (auspex) lists accounts whose email matches a glob. SET
RESTRICTED makes a channel kick anyone without access (or oper) as they
join, mirroring the SECUREOPS on-join enforcement.
This commit is contained in:
Jean Chevronnet 2026-07-15 19:25:41 +00:00
parent be4860c9a8
commit 53d3d63464
No known key found for this signature in database
10 changed files with 107 additions and 2 deletions

View file

@ -22,6 +22,12 @@ impl Store for Db {
.map(|a| AccountView { name: a.name.clone(), email: a.email.clone(), ts: a.ts, verified: a.verified, greet: a.greet.clone() })
.collect()
}
fn accounts_by_email(&self, pattern: &str) -> Vec<String> {
self.accounts()
.filter(|a| a.email.as_deref().is_some_and(|e| super::glob_match(pattern, e)))
.map(|a| a.name.clone())
.collect()
}
fn authenticate(&self, name: &str, password: &str) -> Option<&str> {
Db::authenticate(self, name, password)
}