Remove ExpiredOn during password-modify

tags/smeserver-expire-accounts-0.1.7-1
Daniel Berteaud 9 years ago
parent ce04810f43
commit 1b5388eae4
  1. 5
      createlinks
  2. 20
      root/etc/e-smith/events/actions/user-reset-expired

@ -0,0 +1,5 @@
#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
event_link("user-reset-expired", 'password-modify', "80");

@ -0,0 +1,20 @@
#!/usr/bin/perl -w
use strict;
use esmith::AccountsDB;
my $a = esmith::AccountsDB->open || die "Couldn't open the AccountsDB\n";
my $event = $ARGV[0];
my $user = $ARGV[1];
if (!$event){
die "Event must be specified\n";
}
if (!$user){
die "User must be specified\n";
}
my $rec = $a->get($user) || die "user $user not found in AccountsDB\n";
$rec->del_prop('ExpireLockedOn');
Loading…
Cancel
Save