Issue #393 has been reported by Stéphane Baud.
----------------------------------------
Bug #393: self-service-password 0.7 (latest version)
http://tools.lsc-project.org/issues/393
Author: Stéphane Baud
Status: New
Priority: Normal
Assigned to:
Category:
Target version:
Not having any forbidden characters, i.e. $pwd_forbidden_chars = ""; in
conf.config.in.php triggers the following warning :
[Mon Jan 30 17:40:40 2012] [error] [client 172.23.1.214] PHP Warning:
preg_match_all(): Compilation failed: missing terminating ] for character class
at offset 2 in /application/pwdreset/test/lib/functions.inc.php on line 153
The corresponding code :
preg_match_all("/[$pwd_forbidden_chars]/", $password, $forbidden_res);
$forbidden = count( $forbidden_res[0] );
should include a test for both existence and non emptyness of
$pwd_forbidden_chars and should be replaced by something like this :
$forbidden = 0;
if ( isset($pwd_forbidden_chars) && !empty($pwd_forbidden_chars) ) {
preg_match_all("/[$pwd_forbidden_chars]/", $password, $forbidden_res);
$forbidden = count( $forbidden_res[0] );
}
Please note that the same applies to special characters ($pwd_special_chars)
which will trigger the same warning if undefined or empty.
--
You have received this notification because you have either subscribed to it,
or are involved in it.
To change your notification preferences, please click here:
http://tools.lsc-project.org/my/account
_______________________________________________
ltb-dev mailing list
[email protected]
http://lists.ltb-project.org/listinfo/ltb-dev