diff options
author | cyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-11-15 19:13:07 +0000 |
---|---|---|
committer | cyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-11-15 19:13:07 +0000 |
commit | 675c8dc34ac7002df34e154264574c741b61d64d (patch) | |
tree | 16099a3e2aa5287febefe4877cafa57a30d7a303 | |
parent | ba15bdc174971c7f5b8e3652d03d31291efa440e (diff) |
Added badpasslimit directive to options block in new config.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1709 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r-- | data/example_new.conf | 11 | ||||
-rw-r--r-- | src/config.c | 2 |
2 files changed, 12 insertions, 1 deletions
diff --git a/data/example_new.conf b/data/example_new.conf index 1adecfb4b..129dea7da 100644 --- a/data/example_new.conf +++ b/data/example_new.conf @@ -275,6 +275,17 @@ options { * as well. This directive is optional, but recommended. */ strictpasswords = yes + + /* + * Sets the number of invalid password tries before Services removes a user + * from the network. If a user enters a number of invalid passwords equal to + * the given amount for any Services function or combination of functions + * during a single IRC session (subject to badpasstimeout, below), Services + * will issues a /KILL for the user. If not given, Services will ignore + * failed password attempts (though they will be logged in any case). This + * directive is optional, but recommended. + */ + badpasslimit = 5 } /* diff --git a/src/config.c b/src/config.c index 7b0dc2045..b57ddc683 100644 --- a/src/config.c +++ b/src/config.c @@ -640,6 +640,7 @@ int ServerConfig::Read(bool bail) {"options", "userkey3", "0", new ValueContainerLUInt(&UserKey3), DT_LUINTEGER, NoValidation}, {"options", "nobackupokay", "no", new ValueContainerBool(&NoBackupOkay), DT_BOOLEAN, NoValidation}, {"options", "strictpasswords", "no", new ValueContainerBool(&StrictPasswords), DT_BOOLEAN, NoValidation}, + {"options", "badpasslimit", "0", new ValueContainerInt(&BadPassLimit), DT_INTEGER, NoValidation}, {"nickserv", "nick", "NickServ", new ValueContainerChar(&s_NickServ), DT_CHARPTR | DT_NORELOAD, ValidateNotEmpty}, {"nickserv", "description", "Nickname Registration Service", new ValueContainerChar(&desc_NickServ), DT_CHARPTR | DT_NORELOAD, ValidateNotEmpty}, {"nickserv", "database", "nick.db", new ValueContainerChar(&NickDBName), DT_CHARPTR, ValidateNotEmpty}, @@ -1351,7 +1352,6 @@ bool ValueItem::GetBool() /*************************************************************************/ Directive directives[] = { - {"BadPassLimit", {{PARAM_POSINT, PARAM_RELOAD, &BadPassLimit}}}, {"BadPassTimeout", {{PARAM_TIME, PARAM_RELOAD, &BadPassTimeout}}}, {"DumpCore", {{PARAM_SET, 0, &DumpCore}}}, {"ExpireTimeout", {{PARAM_TIME, PARAM_RELOAD, &ExpireTimeout}}}, |