Add a mode option, which is passed through to mlock to set the modes
on channels. Individual channels can override the global setting.
Because you must be an operator in the channel you are forwarding to
when using the +f mode, add a op_channel option that pre-joins a given
channel and promotes ourselves to ops in there.
[1] https://wiki.swiftirc.net/wiki/Chanserv#Mlock
Change-Id: Ic3ea018f1dd3032a628030ed56cfd863de2f159d
By design, accessbot doesn't *remove* access when you remove yourself
from the access lists; you are just limited to a lower level. This is
noted in the configuration file:
# The label 'mask' is special: anyone with perms on a channel that
# isn't otherwise listed for the channel or in the global list will
# have their access limited to the mask but otherwise left alone.
However I'm feel like it's reasonable to assume that when you remove
yourself you are giving up your permissions; and in the *very*
unlikely case of a bad actor, we would want to know we did actually
remove them from all channels.
To make this clearer, but still allow for unlisted users to maintain
whatever permissions they have, this adds an "alumni" section to the
configuration, and allows for alumni to be set on individual channels.
If your nick appears in this list, your access is removed.
Obviously once this has run once, people could be removed from alumni
if there is a need to cater for something tricky like removing global
access but then adding permissions. But in general I think it will
work to just keep a record of contributors in the common case of
"moved on from openstack work and no longer want to admin things".
Change-Id: I0858e963cdf4bc90c30f9d60ea524d778ae3d150
Run it whenever there is a change to the YAML channel config.
The script will ensure everyone listed in global has those perms
and anyone else found with access on a channel will be left as-is
except that their access will be limited to the relevant mask.
Move it and the previous change to add a permission checking
script into a new module, 'accessbot'.
Support SSL in both scripts.
Add a 1 second sleep in the check script to avoid flood protection.
Add all known channels to the channel config.
Closes-Bug: 1190296
Change-Id: I5072cb56ae83a70f4fa955362b8db909b2956d70