3
0
mirror of https://github.com/pragma-/pbot.git synced 2024-12-24 03:33:06 +01:00

Add whitelist to blacklist check

This commit is contained in:
Pragmatic Software 2016-01-24 03:02:14 -08:00
parent 01eb05a05e
commit 8ac4a5999d

View File

@ -663,6 +663,11 @@ sub check_bans {
$self->{pbot}->{logger}->log("anti-flood: [check-bans] checking blacklist for $alias in channel $channel\n") if $debug_checkban >= 5;
if ($self->{pbot}->{blacklist}->check_blacklist($alias, $channel)) {
if($self->ban_whitelisted($channel, $alias, $mask)) {
$self->{pbot}->{logger}->log("anti-flood: [check-bans] $mask [$alias] evaded blacklist in $channel, but allowed through whitelist\n");
next;
}
my $baninfo = {};
$baninfo->{banmask} = $alias;
$baninfo->{channel} = $channel;