diff options
author | Naram Qashat cyberbotx@cyberbotx.com <Naram Qashat cyberbotx@cyberbotx.com@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-10-26 20:28:48 +0000 |
---|---|---|
committer | Naram Qashat cyberbotx@cyberbotx.com <Naram Qashat cyberbotx@cyberbotx.com@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-10-26 20:28:48 +0000 |
commit | 4ca6d143113760cd5ffa2f00182d939881a30a70 (patch) | |
tree | aedc6ab518656e5fe94c1ce15c10eed2269f7efc | |
parent | 77ae0ef75a4a8c51ac20ada389793a248d840c8a (diff) |
Added opersonly directive to operserv block in new config.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1490 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r-- | data/example_new.conf | 6 | ||||
-rw-r--r-- | include/extern.h | 2 | ||||
-rw-r--r-- | src/config.c | 4 |
3 files changed, 9 insertions, 3 deletions
diff --git a/data/example_new.conf b/data/example_new.conf index 8a76f79cb..224746c67 100644 --- a/data/example_new.conf +++ b/data/example_new.conf @@ -857,4 +857,10 @@ operserv * optional. */ addakiller = yes + + /* + * If set, only IRC Operators will be permitted to use OperServ, regardless of module-based command + * access restrictions. This directive is optional, but recommended. + */ + opersonly = yes } diff --git a/include/extern.h b/include/extern.h index fc39cffaf..b9b03c3c5 100644 --- a/include/extern.h +++ b/include/extern.h @@ -872,7 +872,7 @@ E int check_szline(const char *nick, char *ip); E Server *server_global(Server * s, char *msg); -E int OSOpersOnly; +E bool OSOpersOnly; E time_t DefContimer; E void runDefCon(void); E int defconParseModeString(const char *str); diff --git a/src/config.c b/src/config.c index c7825a5e1..660b69052 100644 --- a/src/config.c +++ b/src/config.c @@ -227,7 +227,7 @@ char *ExceptionDBName; char *SessionLimitExceeded; char *SessionLimitDetailsLoc; -int OSOpersOnly; +bool OSOpersOnly; char *Modules; char *ModulesDelayed; @@ -677,6 +677,7 @@ int ServerConfig::Read(bool bail) {"operserv", "maxsessionkill", "0", new ValueContainerInt(&MaxSessionKill), DT_INTEGER, NoValidation}, {"operserv", "sessionautokillexpiry", "0", new ValueContainerTime(&SessionAutoKillExpiry), DT_TIME, NoValidation}, {"operserv", "addakiller", "no", new ValueContainerBool(&AddAkiller), DT_BOOLEAN, NoValidation}, + {"opserver", "opersonly", "no", new ValueContainerBool(&OSOpersOnly), DT_BOOLEAN, NoValidation}, {NULL, NULL, NULL, NULL, DT_NOTHING, NoValidation} }; /* These tags can occur multiple times, and therefore they have special code to read them @@ -1323,7 +1324,6 @@ Directive directives[] = { {"ServerDesc", {{PARAM_STRING, 0, &ServerDesc}}}, {"ServerName", {{PARAM_STRING, 0, &ServerName}}}, {"ServiceUser", {{PARAM_STRING, 0, &temp_userhost}}}, - {"OSOpersOnly", {{PARAM_SET, PARAM_RELOAD, &OSOpersOnly}}}, {"HideStatsO", {{PARAM_SET, PARAM_RELOAD, &HideStatsO}}}, {"GlobalOnCycle", {{PARAM_SET, PARAM_RELOAD, &GlobalOnCycle}}}, {"AnonymousGlobal", {{PARAM_SET, PARAM_RELOAD, &AnonymousGlobal}}}, |