Added command rate limiting. This adds the config options: ratelimit, ratelimit_amount, ratelimit_time
This commit is contained in:
1 parent
cdb957732c
commit
fa76d4524d
5 files changed
+99
-16
No files matched your search
@@ -144,7 +144,7 @@ if (conf_get('die')) {
|
||||
}
|
||||
|
||||
# Check for required configuration values.
|
||||
my @REQCVALS = qw(locale expire_logs server fantasy_pf);
|
||||
my @REQCVALS = qw(locale expire_logs server fantasy_pf ratelimit);
|
||||
foreach my $REQCVAL (@REQCVALS) {
|
||||
if (!conf_get($REQCVAL)) {
|
||||
my $err = 2;
|
||||
@@ -174,6 +174,9 @@ if (!-e "$Bin/../etc/auto.db") {
|
||||
}
|
||||
our $DB = DBI->connect("dbi:SQLite:dbname=$Bin/../etc/auto.db", q{}, q{});
|
||||
|
||||
# Ratelimit timer.
|
||||
Core::IRC::clear_usercmd_timer();
|
||||
|
||||
# Parse privileges.
|
||||
our (%PRIVILEGES);
|
||||
# If there are any privsets.
|
||||
|
||||
Reference in new issue
Block a user