diff options
author | Adam <Adam@sigterm.info> | 2019-10-14 13:13:08 -0400 |
---|---|---|
committer | Adam <Adam@sigterm.info> | 2019-10-14 13:13:08 -0400 |
commit | c15dc499948f494c826a63a7510f1167f513ba4f (patch) | |
tree | a49af51e417f01a05f7f50a5906d1ea6b5444b91 | |
parent | 14ee76a0ad8d4ddd150ff91d71a8d845ef015ece (diff) |
ns_recover: add privilege for admins to recover other users
-rw-r--r-- | data/example.conf | 1 | ||||
-rw-r--r-- | modules/commands/ns_recover.cpp | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/data/example.conf b/data/example.conf index 371e71bae..7416401c5 100644 --- a/data/example.conf +++ b/data/example.conf @@ -779,6 +779,7 @@ log * nickserv/auspex - Can see any information with /NICKSERV INFO * nickserv/confirm - Can confirm other users nicknames * nickserv/drop - Can drop other users nicks + * nickserv/recover - Can recover other users nicks * operserv/config - Can modify services's configuration * operserv/oper/modify - Can add and remove operators with at most the same privileges * protected - Can not be kicked from channels by Services diff --git a/modules/commands/ns_recover.cpp b/modules/commands/ns_recover.cpp index d0704356d..afbca27f1 100644 --- a/modules/commands/ns_recover.cpp +++ b/modules/commands/ns_recover.cpp @@ -187,6 +187,9 @@ class CommandNSRecover : public Command if (source.GetUser() && !source.GetUser()->fingerprint.empty() && cl && cl->FindCert(source.GetUser()->fingerprint)) ok = true; + if (source.HasPriv("nickserv/recover")) + ok = true; + if (ok == false && !pass.empty()) { NSRecoverRequest *req = new NSRecoverRequest(owner, source, this, na->nick, pass); |