geoip: native maxmind .mmdb reader, G: geoban extban, GEOIP command, whois country

This commit is contained in:
Jean Chevronnet 2026-08-09 21:43:57 +00:00
parent aa384d56f2
commit 7a99f49ca4
7 changed files with 406 additions and 2 deletions

View file

@ -262,6 +262,10 @@ impl Command for Whois {
if let Some(line) = crate::modules::whoisport::line(s, tuid) {
s.numeric(uid, RPL_WHOISSPECIAL, &format!(":{line}"));
}
// geoip: the country the user connects from — opers only
if let Some(line) = crate::modules::geoip::whois_line(s, tuid) {
s.numeric(uid, RPL_WHOISSPECIAL, &format!(":{line}"));
}
}
// opers can see through the cloak to the real host/ip
if asker_oper && disp != realhost {