Add masterpassword private-only command
This commit is contained in:
parent
5dd337a92e
commit
a031402c1d
1 changed files with 8 additions and 0 deletions
|
@ -25,6 +25,14 @@ class Module(ModuleManager.BaseModule):
|
|||
print("one-time master password: %s" % master_password)
|
||||
else:
|
||||
raise ValueError("Unknown command-line argument")
|
||||
@utils.hook("received.command.masterpassword", private_only=True)
|
||||
def master_password(self, event):
|
||||
"""
|
||||
:permission: master-password
|
||||
"""
|
||||
master_password = self._master_password()
|
||||
event["stdout"].write("One-time master password: %s" %
|
||||
master_password)
|
||||
|
||||
@utils.hook("received.part")
|
||||
def on_part(self, event):
|
||||
|
|
Loading…
Reference in a new issue