aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Fischer <bantu@phpbb.com>2011-03-25 23:15:40 +0100
committerAndreas Fischer <bantu@phpbb.com>2011-04-01 15:10:29 +0200
commit4dce53628c97062b1085eb714892f6d81ae07699 (patch)
tree34173aebc188236c282b3a11a6841142c146cd56
parent7cc32d3843afbb754b3de101bda2267012647c2f (diff)
downloadforums-4dce53628c97062b1085eb714892f6d81ae07699.tar
forums-4dce53628c97062b1085eb714892f6d81ae07699.tar.gz
forums-4dce53628c97062b1085eb714892f6d81ae07699.tar.bz2
forums-4dce53628c97062b1085eb714892f6d81ae07699.tar.xz
forums-4dce53628c97062b1085eb714892f6d81ae07699.zip
[ticket/9751] Add shortcut logic for pass_complex == PASS_TYPE_ANY.
Add shortcut logic for pass_complex because this is the default value phpBB ships with and there is nothing to do in that function in that case. PHPBB3-9751
-rw-r--r--phpBB/includes/functions_user.php6
1 files changed, 2 insertions, 4 deletions
diff --git a/phpBB/includes/functions_user.php b/phpBB/includes/functions_user.php
index 6ac6317dd2..89ce52dc39 100644
--- a/phpBB/includes/functions_user.php
+++ b/phpBB/includes/functions_user.php
@@ -1605,8 +1605,9 @@ function validate_password($password)
{
global $config, $db, $user;
- if ($password === '')
+ if ($password === '' || $config['pass_complex'] === 'PASS_TYPE_ANY')
{
+ // Password empty or no password complexity required.
return false;
}
@@ -1659,9 +1660,6 @@ function validate_password($password)
case 'PASS_TYPE_CASE':
$chars[] = $low;
$chars[] = $upp;
-
- // No requirements
- case 'PASS_TYPE_ANY':
}
if ($pcre)