-
Notifications
You must be signed in to change notification settings - Fork 0
Configuration
In no-services, there are several configuration options you can use to better manage how things work on your network. Please bear in mind this project is still very early on.
Configuration of no-services is done through your unrealircd.conf
or other included file, and so follows the same configuration syntax as UnrealIRCd.
To configure no-services, start by creating a no-services
block:
no-services {
[...]
}
You can define your API endpoint and API key using the api-url
and api-key
options.
no-services {
api-url 'https://example.com/endpoint/v1/'; // you should use single quotes for this URL
api-key "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890"; // Your API key
[...]
}
And with that, that's the mandatory configuration out of the way! The rest is all optional or has default values.
Inside your no-services
block, you can create an account-registration
sub-block. This will have its own options for you to choose.
Here are the defaults which provide all the options available:
no-services {
[...]
account-registration {
options {
before-connect; // Allow users to register before they're fully connected like SASL
custom-account-name; // Allow users to specify a custom account name. Required if you want to use before-connect
email-required; // Require users to provide a valid email.
}
password-strength 4; // Password strength requirements of registering users, 0-4. Default is 4.
}
}
You can choose what the "Guest" nick should be, and how long users have by default to identify before their nick is changed when attempting to use a registered account:
no-services {
[...]
guest-nick "Guest";
nick-enforcement-timeout 2m; // two minutes
}
You can add your own IRC-Services-style bots and tie server commands to each bot. When using 'no-services'-specific commands, the response will come from the bot instead. For example if you tied the AJOIN
command to a bot called NickServ
and did /msg NickServ ajoin add #support
, the response would come from NickServ. However if you just did /AJOIN add #support
, the server would reply using Standard Replies.
Here is an example for adding your own bots, tying commands to them and specifying their help outputs. This will be improved further in the future.
no-services {
[...]
bot {
NickServ {
register "Register an account";
ajoin "Manage your auto-join list";
setpassword "Set a new password for your account";
drop "Drop your account";
release "Release a hold on your account";
certfp "Manage your certificate fingerprint list";
logout "Log out of your account";
identify "Identify to an account using a password";
}
ChanServ {
cregister "Register a channel to your account";
}
OperServ {
salogout "Forcefully logout a user";
sadrop "Forcefully drop an account";
}
BotBot {
}
TestServ { }
}
}
Note that these clients are 100% fake and so you cannot /kill them or /whois them like normal users or services.
Well, that's it so far for no-services
-specific configuration!
You can use UnrealIRCd's set::restrict-commands
feature to limit things like account and channel registrations to fine-tuned criteria. This really puts you in control of what happens on your network:
set {
restrict-commands {
register {
except {
reputation-score 100;
}
};
cregister {
except {
reputation-score 500;
}
};
}
}