mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-09 02:06:32 +02:00
Prevent reuse of previous password
git-svn-id: file:///svn/phpbb/trunk@6424 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -83,6 +83,12 @@ class ucp_profile
|
||||
$error[] = 'CUR_PASSWORD_ERROR';
|
||||
}
|
||||
|
||||
// Only check the new password against the previous password if there have been no errors
|
||||
if (!sizeof($error) && $auth->acl_get('u_chgpasswd') && $new_password && md5($new_password) == $user->data['user_password'])
|
||||
{
|
||||
$error[] = 'SAME_PASSWORD_ERROR';
|
||||
}
|
||||
|
||||
if ($auth->acl_get('u_chgemail') && $email != $user->data['user_email'] && $email_confirm != $email)
|
||||
{
|
||||
$error[] = 'NEW_EMAIL_ERROR';
|
||||
|
Reference in New Issue
Block a user