From 0c3eeb1ae4888d0e761f852c0073ab57ad628d0b Mon Sep 17 00:00:00 2001 From: w00t Date: Wed, 31 Oct 2007 12:12:30 +0000 Subject: Clean up XLine conf stuff a little bit, move most of it to configreader. Also, check elines and call ApplyLines on both rehash and startup. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8425 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/configreader.h | 25 +++++++++++++++++++++++++ include/xline.h | 31 +++++-------------------------- 2 files changed, 30 insertions(+), 26 deletions(-) (limited to 'include') diff --git a/include/configreader.h b/include/configreader.h index 37e3c1f44..1a14a2854 100644 --- a/include/configreader.h +++ b/include/configreader.h @@ -803,5 +803,30 @@ bool DoClass(ServerConfig* conf, const char* tag, char** entries, ValueList &val */ bool DoneClassesAndTypes(ServerConfig* conf, const char* tag); + + +/** Initialize x line + */ +bool InitXLine(ServerConfig* conf, const char* tag); + +/** Add a config-defined zline + */ +bool DoZLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); + +/** Add a config-defined qline + */ +bool DoQLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); + +/** Add a config-defined kline + */ +bool DoKLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); + +/** Add a config-defined eline + */ +bool DoELine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); + + + + #endif diff --git a/include/xline.h b/include/xline.h index 7bf291253..6540d57f6 100644 --- a/include/xline.h +++ b/include/xline.h @@ -304,36 +304,10 @@ class CoreExport QLine : public XLine class ServerConfig; class InspIRCd; -/** Initialize x line - */ -bool InitXLine(ServerConfig* conf, const char* tag); - -/** Done adding zlines from the config - */ -bool DoneZLine(ServerConfig* conf, const char* tag); -/** Done adding qlines from the config - */ -bool DoneQLine(ServerConfig* conf, const char* tag); -/** Done adding klines from the config - */ -bool DoneKLine(ServerConfig* conf, const char* tag); /** Done adding elines from the config */ bool DoneELine(ServerConfig* conf, const char* tag); -/** Add a config-defined zline - */ -bool DoZLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); -/** Add a config-defined qline - */ -bool DoQLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); -/** Add a config-defined kline - */ -bool DoKLine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); -/** Add a config-defined eline - */ -bool DoELine(ServerConfig* conf, const char* tag, char** entries, ValueList &values, int* types); - /** Contains an ident and host split into two strings */ typedef std::pair IdentHostPair; @@ -371,6 +345,11 @@ class CoreExport XLineManager */ IdentHostPair IdentSplit(const std::string &ident_and_host); + /** Checks what users match a given list of ELines and sets their ban exempt flag accordingly. + * @param ELines List of E:Lines to check. + */ + void CheckELines(std::map &ELines); + /** Add a new GLine * @param duration The duration of the line * @param source The source of the line -- cgit v1.2.3