Anti-join flood bans for 2^5 hours for first offense instead of 2^7 hours (now uses 2^(4+number_of_offenses) hours as timeout)

This commit is contained in:
Pragmatic Software 2010-06-27 11:13:30 +00:00
parent 2d11d66b67
commit fe6d08178b
2 changed files with 3 additions and 3 deletions

View File

@ -209,7 +209,7 @@ sub check_flood {
if(${ $self->message_history }{$account}{$channel}{join_watch} >= $max_messages) {
${ $self->message_history }{$account}{$channel}{offenses}++;
my $timeout = (2 ** (($self->message_history->{$account}{$channel}{offenses} + 4) < 10 ? ${ $self->message_history }{$account}{$channel}{offenses} + 6 : 10));
my $timeout = (2 ** (($self->message_history->{$account}{$channel}{offenses} + 4) < 10 ? ${ $self->message_history }{$account}{$channel}{offenses} + 4 : 10));
my $banmask = address_to_mask($host);

View File

@ -13,8 +13,8 @@ use warnings;
# These are set automatically by the build/commit script
use constant {
BUILD_NAME => "PBot",
BUILD_REVISION => 208,
BUILD_DATE => "2010-06-26",
BUILD_REVISION => 209,
BUILD_DATE => "2010-06-27",
};
1;