This site is deprecated; docs have moved to docs.inspircd.org!
Opers And InspIRCd
Those of you used to other IRCds will be surprised by the level of flexibility provided by opers in InspIRCd. Instead of oper flags, InspIRCd has oper classes. An oper class is a group of commands and an oper type is a group of classes. For a short summary, see the diagram below which shows the relationships between classes, types and opers:
So for example, based upon this diagram we know that we can have multiple classes to a type, but only one type per oper, however multiple opers may use the type definitions. Here is an example:
<class name="ShutDownCommands" commands="DIE RESTART"> <class name="ModuleCommands" commands="LOADMODULE UNLOADMODULE"> <type name="OperTypeOne" classes="ShutDownCommands" host="oper.type.one"> <type name="OperTypeTwo" classes="ModuleCommands" host="oper.type.two"> <type name="OperTypeThree" classes="ShutDownCommands ModuleCommands" host="oper.type.three"> <oper name="OperOne" password="One" host="*@*" type="OperTypeOne"> <oper name="OperTwo" password="Two" host="*@*" type="OperTypeTwo"> <oper name="OperThree" password="Three" host="*@*" type="OperTypeThree">
We have defined two classes, three types, and three opers. Based upon the relationship diagram specified above, we now know that:
- Oper OperOne can execute commands: DIE, RESTART
- Oper OperTwo can execute commands: LOADMODULE, UNLOADMODULE
- Oper OperThree can execute commands: DIE, RESTART, LOADMODULE, UNLOADMODULE
The grouping of commands into classes is done primarily for you, the admin of the server, as it helps you keep your commands organised. It is recommended that you group together commands of similar effect, for example SANICK, SAQUIT etc, however you are not forced to place any two commands together.
All commands, even those added by modules, are forced to obey the oper class layout, so if you add a module which adds an oper-only command, you must remember to also add its commands to the relevent oper classes.
For a list of oper commands, please see InspIRCd Oper Commands
You can also create a class with commands="*", to allow that class to execute all oper commands (including those added by modules).
I hope this tutorial has been of use to you, and that you enjoy using InspIRCd!