mod_auth_simple
Authenticate users from a plain text file. Part of the bundled plug-ins.
mod_auth_simple reads registered accounts from a flat text file. It is the
simplest way to add a handful of registered users, operators and admins without a database.
Loading
plugin /var/lib/uhub/mod_auth_simple.so "file=/etc/uhub/users.conf"
Configuration
| Option | Default | Description |
|---|---|---|
file | — | Path to the accounts file (required). |
readonly | yes | The hub never writes back to the file; registration/update/delete are refused. |
exclusive | no | When enabled, only accounts listed in this file may log in — any other nick is denied instead of being passed on to another auth plug-in. |
File format
One account per line, whitespace-separated:
credential username password
credential is one of admin, super,
op/operator, reg/user or a bot class
(bot, ubot, opbot, opubot). For example:
admin alice s3cr3t
op bob hunter2
reg carol passw0rd
Changed in 0.8.0: registered accounts are no longer defined in the hub's
file_acl ACL file — an authentication plug-in such as this one is now the only
place they live. If you are upgrading, move any user_admin /
user_op / user_reg lines out of the ACL file and into this
format.
Fixed in 0.8.0: if the accounts file cannot be read, the plug-in now fails
to load instead of starting with an empty account list. Previously an unreadable file
combined with exclusive=1 would lock every user out of the hub.
For a database-backed store, ban persistence and self-service registration, see mod_auth_sqlite.