diff --git a/forgot.cgi b/forgot.cgi index 4a6ec9015..ecfbdaf12 100755 --- a/forgot.cgi +++ b/forgot.cgi @@ -10,6 +10,7 @@ $trust_unknown_referers = 1; $gconfig{'forgot_pass'} || &error($text{'forgot_ecannot'}); my $forgot_timeout = 10; &error_setup($text{'forgot_err'}); +$remote_user && &error($text{'forgot_elogin'}); # Check that the random ID is valid $in{'id'} =~ /^[a-f0-9]+$/i || &error($text{'forgot_eid'}); diff --git a/forgot_form.cgi b/forgot_form.cgi index e082711b0..855523ebf 100755 --- a/forgot_form.cgi +++ b/forgot_form.cgi @@ -6,7 +6,10 @@ use WebminCore; $no_acl_check++; &init_config(); &ReadParse(); + +&error_setup($text{'forgot_err'}); $gconfig{'forgot_pass'} || &error($text{'forgot_ecannot'}); +$remote_user && &error($text{'forgot_elogin'}); &ui_print_header(undef, $text{'forgot_title'}, "", undef, undef, 1, 1); diff --git a/forgot_send.cgi b/forgot_send.cgi index 8257889f8..391ba39a2 100755 --- a/forgot_send.cgi +++ b/forgot_send.cgi @@ -6,7 +6,10 @@ use WebminCore; $no_acl_check++; &init_config(); &ReadParse(); + +&error_setup($text{'forgot_err'}); $gconfig{'forgot_pass'} || &error($text{'forgot_ecannot'}); +$remote_user && &error($text{'forgot_elogin'}); # Lookup the Webmin user &foreign_require("acl"); diff --git a/lang/en b/lang/en index 75bbb3ada..f5e0a9814 100644 --- a/lang/en +++ b/lang/en @@ -164,7 +164,7 @@ forgot_passok=Change Password forgot_euser2=Webmin user $1 does not exist! forgot_esync=The password cannot be changed for this user forgot_elock=The password for this user is locked -forgot_err=Failed to change password +forgot_err=Failed to reset password forgot_enewpass=No new password entered! forgot_equality=Password requirements were not met : $1 forgot_wdoing=Changing password for Webmin user $1 .. @@ -175,6 +175,7 @@ forgot_vdoing=Changing password for Virtualmin domain $1 .. forgot_udoing=Changing password for Unix user $1 .. forgot_eunix=Unix user does not exist! forgot_eunixlock=User user's password is locked! +forgot_elogin=Forgotted password pages cannot be used when you are already logged in to Webmin! pam_header=Login to Webmin pam_mesg=You must respond to the question below to login to Webmin server on $1.