]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/coremods/core_oper/core_oper.h
Clean up the logic for parsing oper mode privileges.
[user/henk/code/inspircd.git] / src / coremods / core_oper / core_oper.h
index db8c4161c8672ee9253587fc868cf5f660b8d4dd..d20d91e8eb4dbaa80a8d6df4f1523a81c9f1faf7 100644 (file)
@@ -1,7 +1,9 @@
 /*
  * InspIRCd -- Internet Relay Chat Daemon
  *
- *   Copyright (C) 2014 Attila Molnar <attilamolnar@hush.com>
+ *   Copyright (C) 2018 linuxdaemon <linuxdaemon.irc@gmail.com>
+ *   Copyright (C) 2017-2018 Sadie Powell <sadie@witchery.services>
+ *   Copyright (C) 2014-2015, 2018 Attila Molnar <attilamolnar@hush.com>
  *
  * This file is part of InspIRCd.  InspIRCd is free software: you can
  * redistribute it and/or modify it under the terms of the GNU General Public
 
 namespace DieRestart
 {
-       /** Checks a die or restart password
-        * @param user The user executing /DIE or /RESTART
-        * @param inputpass The password given by the user
-        * @param confkey The name of the key in the power tag containing the correct password
-        * @return True if the given password was correct, false if it was not
-        */
-       bool CheckPass(User* user, const std::string& inputpass, const char* confkey);
-
        /** Send an ERROR to unregistered users and a NOTICE to all registered local users
         * @param message Message to send
         */
@@ -42,9 +36,12 @@ namespace DieRestart
 class CommandDie : public Command
 {
  public:
+       std::string& hash;
+       std::string password;
+
        /** Constructor for die.
         */
-       CommandDie(Module* parent);
+       CommandDie(Module* parent, std::string& hashref);
 
        /** Handle command.
         * @param parameters The parameters to the command
@@ -63,6 +60,12 @@ class CommandKill : public Command
        ClientProtocol::EventProvider protoev;
 
  public:
+       /** Set to a non empty string to obfuscate nicknames prepended to a KILL. */
+       std::string hidenick;
+
+       /** Set to hide kills from clients of ulined servers in snotices. */
+       bool hideuline;
+
        /** Constructor for kill.
         */
        CommandKill(Module* parent);
@@ -73,6 +76,7 @@ class CommandKill : public Command
         * @return A value from CmdResult to indicate command success or failure.
         */
        CmdResult Handle(User* user, const Params& parameters) CXX11_OVERRIDE;
+
        RouteDescriptor GetRouting(User* user, const Params& parameters) CXX11_OVERRIDE;
 
        void EncodeParameter(std::string& param, unsigned int index) CXX11_OVERRIDE;
@@ -117,9 +121,12 @@ class CommandRehash : public Command
 class CommandRestart : public Command
 {
  public:
+       std::string& hash;
+       std::string password;
+
        /** Constructor for restart.
         */
-       CommandRestart(Module* parent);
+       CommandRestart(Module* parent, std::string& hashref);
 
        /** Handle command.
         * @param user User issuing the command