This checks the nickname of a joining user against a configurable Lua pattern, and prevents them from joining if it does not match.
There is a single configuration option,
muc_restrict_nick_pattern
and the default is
"^%w+$"
- i.e. allow only alphanumeric characters in
nicknames.
Requires Prosody 0.11 or higher.
With the plugin installer in Prosody 0.12 you can use:
sudo prosodyctl install --server=https://modules.prosody.im/rocks/ mod_muc_restrict_nick
For earlier versions see the documentation for installing 3rd party modules