Fail if password change prompt is checked but won't work

This commit is contained in:
Jamie Cameron
2009-08-24 21:13:39 -07:00
parent f07a6bc6fc
commit bc10057b6e
2 changed files with 6 additions and 0 deletions
+1
View File
@@ -125,6 +125,7 @@ save_eminsize=Missing or non-numeric minimum password length
save_edays=No days to allow selected
save_ehours=Missing or invalid times to allow
save_ehours2=Start time to allow must be before end
save_etemp=The option to force a password change at next login cannot be used unless <a href='$1'>prompting users to enter new passwords</a> is enabled
delete_err=Failed to delete user
delete_eself=You cannot delete yourself
+5
View File
@@ -314,6 +314,11 @@ elsif ($in{'lock'} && $user{'pass'} !~ /^\!/ && $in{'pass_def'} <= 1) {
# Check for force change
$user{'temppass'} = $in{'temp'};
if ($in{'temp'}) {
&get_miniserv_config(\%miniserv);
$miniserv{'passwd_mode'} == 2 ||
&error(&text('save_etemp', '../webmin/edit_session.cgi'));
}
if ($in{'old'}) {
# update user and all ACLs