2019-04-15 15:59:27 +00:00
## Setting up BitBot
2019-10-17 13:21:56 +00:00
* Move `docs/bot.conf.example` to `~/.bitbot/bot.conf` and fill in the config options you care about. Ones blank or removed will disable relevant functionality.
2019-10-11 16:04:11 +00:00
* Run `./bitbotd -a` to add a server.
* Run `./bitbotd` to start the bot.
2020-03-08 19:45:11 +00:00
* Run `./bitbotctl command master-password` to get the master admin password (needed to add regular admin accounts)
2019-04-15 15:59:27 +00:00
* Join `#bitbot` on a server with the bot (or invite it to another channel)
2019-04-15 16:05:59 +00:00
* `/msg <bot> register <password here>` to register your nickname with the bot
2019-07-04 09:54:41 +00:00
* (use `/msg <bot> identify <password>` to log in in the future)
2019-04-15 16:05:59 +00:00
* `/msg <bot> masterlogin <master admin password>` to login as master admin
2019-12-28 11:19:17 +00:00
* `/msg <bot> permission add <your nickname> *` to give your account admin permissions
2019-04-15 15:59:27 +00:00
### Configure client TLS certificate
Generate a TLS keypair and point `bot.conf` 's `tls-key` to the private key and `tls-certificate` to the public key.
2021-02-12 16:31:13 +00:00
Below is an OpenSSL command example that will create a `bitbot-cert.pem` and `bitbot-key.pem` with `10y` validity (self-signed):
> openssl req -x509 -nodes -sha512 -newkey rsa:4096 -keyout bitbot-key.pem -out bitbot-cert.pem -days 3650 -subj "/CN=YourBotNick"
2019-04-15 15:59:27 +00:00
### Configure SASL
Configure the bot to use SASL to authenticate (usually used for `NickServ` identification)
`EXTERNAL` usually mean client TLS certificate authentication; `USERPASS` is a BitBot-specific term that selects the strongest user/password algorithm.
2019-04-15 16:04:43 +00:00
> /msg <bot> config server sasl userpass <username>:<password>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config server sasl plain <username>:<password>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config server sasl scram-sha-1 <username>:<password>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config server sasl scram-sha-256 <username>:<password>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config server sasl external
2019-04-15 15:59:27 +00:00
### Commands on-connect
2019-07-03 10:26:08 +00:00
The `perform.py` module allows the bot to execute a saved list of raw IRC commands against a server it's connecting to. Use `/msg <bot> perform add <raw irc command>` to add to the current server's list of commands (`{NICK}` in a raw command will be replaced with the bot's current nick.)
2019-04-15 15:59:27 +00:00
### Config options
#### View available config options
2019-04-15 16:04:43 +00:00
> /msg <bot> config bot|server|channel|user
2019-04-15 15:59:27 +00:00
#### Set config options
2019-04-15 16:04:43 +00:00
> /msg <bot> config bot <setting> <value>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config server <setting> <value>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config channel:#bitbot <setting> <value>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config user <setting> <value>
2019-04-15 16:03:29 +00:00
2019-04-15 16:04:43 +00:00
> /msg <bot> config user:other_user <setting> <value>