From 30b22d2b48ecdeac906c69fb28d6df2ef782f792 Mon Sep 17 00:00:00 2001 From: brain Date: Fri, 22 Apr 2005 15:10:11 +0000 Subject: Added OnOperCompare function to override strcmp in password check for /oper git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@1161 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/modules.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'include') diff --git a/include/modules.h b/include/modules.h index 1e0fcf936..57a7a1e04 100644 --- a/include/modules.h +++ b/include/modules.h @@ -619,6 +619,14 @@ class Module : public classbase * may be able to use for pre-determined purposes (e.g. the results of an SQL query, etc). */ virtual char* OnRequest(Request* request); + + /** Called whenever an oper password is to be compared to what a user has input. + * The password field (from the config file) is in 'password' and is to be compared against + * 'input'. This method allows for encryption of oper passwords and much more besides. + * You should return a nonzero value if you want to allow the comparison or zero if you wish + * to do nothing. + */ + virtual int OnOperCompare(std::string password, std::string input); }; -- cgit v1.3.1-10-gc9f91