diff options
| author | 2015-03-01 05:07:13 +0400 | |
|---|---|---|
| committer | 2015-03-01 05:07:13 +0400 | |
| commit | 4fc0df97f75404d7e482be7cd82ba54bcce39f49 (patch) | |
| tree | 90bffcb939c1390a5171943678e371fb4b53497c /config-default | |
| parent | 15f06dc6f79d4642f41f93231d752e6e2e79ccaf (diff) | |
Add ;delwebuser command to complement ;;addwebuser
Diffstat (limited to 'config-default')
| -rw-r--r-- | config-default/commands.xml | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/config-default/commands.xml b/config-default/commands.xml index 8ef69b4..06243a2 100644 --- a/config-default/commands.xml +++ b/config-default/commands.xml @@ -34,6 +34,18 @@ $conn->privmsg($event->replyto, "Added $user to the list of authorized web users.") ]]> </command> + <command cmd="^;delwebuser (\S+)" flag="a"> + <![CDATA[ + my $user = $1; + use Apache::Htpasswd; use Apache::Htgroup; + my $o_Htpasswd = new Apache::Htpasswd({passwdFile => $::settings->{web}->{userfile}, UseMD5 => 1}); + my $o_Htgroup = new Apache::Htgroup($::settings->{web}->{groupfile}); + $o_Htpasswd->htDelete($user); + $o_Htgroup->deleteuser($user, 'actionlogs'); + $o_Htgroup->save(); + $conn->privmsg($event->replyto, "Removed $user from the list of authorized web users.") + ]]> + </command> <command cmd="^;teredo (\S+)"> <