Disallow mutating commands in Aka/Alias/Scheduler by default.

It's too easy to abuse these commands when owners don't know they have to set
the appropriate anticapabilities; so let's set the anticapabilities by default.
This commit is contained in:
Valentin Lorentz 2019-07-31 23:00:55 +02:00
parent dba0ae3771
commit bf7db13f01

View File

@ -1175,7 +1175,13 @@ class DefaultCapabilities(SpaceSeparatedListOfCapabilities):
self.value.add('-owner')
conf.registerGlobalValue(conf.supybot, 'capabilities',
DefaultCapabilities(['-owner', '-admin', '-trusted'], """These are the
DefaultCapabilities([
'-owner', '-admin', '-trusted',
'-aka.add', '-aka.set', '-aka.remove',
'-alias.add', '-alias.remove',
'-scheduler.add', '-scheduler.remove',
],
"""These are the
capabilities that are given to everyone by default. If they are normal
capabilities, then the user will have to have the appropriate
anti-capability if you want to override these capabilities; if they are