solanum
solanum copied to clipboard
extb_extgecos doesn't support CIDRs
Instead of constructing a single string with
snprintf(buf, BUFSIZE, "%s!%s@%s#%s",
client_p->name, client_p->username, client_p->host, client_p->info);
could we instead perform a normal ban match against client_p and then post-process match against the gecos field?
This would require us to split the extban on # instead of constructing a string to match against.
To support this we'd probably want to extend the extban API to pass the matchset through.
We could very easily add in a check of the user's orighost to make $x apply to IPs when an rDNS is present (which we should definitely do). However, match_cidr() does not seem to work when you feed it a banmask with wildcards and causes it to not match. This is also the case with a normal ban too.