system: validatePassword(): also quote the delimiter ('/')
Quoting the default regex delimiter is required for the password complexity check to work if '/' had been specified as special character in Froxlor's account settings.
This commit is contained in:
committed by
Daniel Reichelt
parent
5a6343b47c
commit
67d67a287f
@@ -168,7 +168,7 @@ class Crypt
|
||||
$password = \Froxlor\Validate\Validate::validate($password, '/.*[0-9]+.*/', '/.*[0-9]+.*/', 'notrequiredpasswordcomplexity', array(), $json_response);
|
||||
}
|
||||
if (Settings::Get('panel.password_special_char_required')) {
|
||||
$password = \Froxlor\Validate\Validate::validate($password, '/.*[' . preg_quote(Settings::Get('panel.password_special_char')) . ']+.*/', '/.*[' . preg_quote(Settings::Get('panel.password_special_char')) . ']+.*/', 'notrequiredpasswordcomplexity', array(), $json_response);
|
||||
$password = \Froxlor\Validate\Validate::validate($password, '/.*[' . preg_quote(Settings::Get('panel.password_special_char'), '/') . ']+.*/', '/.*[' . preg_quote(Settings::Get('panel.password_special_char'), '/') . ']+.*/', 'notrequiredpasswordcomplexity', array(), $json_response);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user