diff --git a/includes/User.class.php b/includes/User.class.php index f51220231..d64d696c8 100644 --- a/includes/User.class.php +++ b/includes/User.class.php @@ -375,7 +375,7 @@ public function getAllProperties($format = 'array') */ public function checkPassword($pwd, $newUser = '') { - if (empty($newUser) && $this->properties['password'] != md5($pwd)) { + if (empty($newUser) && $this->properties['password'] !== md5($pwd)) { $this->error = _t('USER_WRONG_PASSWORD').' !'; return false; } else { diff --git a/setup/install.php b/setup/install.php index 948b9cb00..1c41d0f8d 100755 --- a/setup/install.php +++ b/setup/install.php @@ -100,7 +100,7 @@ ); test( _t('CHECKING_THE_ADMIN_PASSWORD_CONFIRMATION').' ...', - $admin_password == $admin_password_conf, + $admin_password === $admin_password_conf, _t('ADMIN_PASSWORD_ARE_DIFFERENT'), 1 ); diff --git a/tools/login/actions/login.php b/tools/login/actions/login.php index 3d7789de5..fa0ef3eed 100755 --- a/tools/login/actions/login.php +++ b/tools/login/actions/login.php @@ -118,7 +118,7 @@ // si l'utilisateur existe, on vérifie son mot de passe if (isset($_POST["name"]) && $_POST["name"] != '' && $existingUser = $this->LoadUser($_POST["name"])) { // si le mot de passe est bon, on créée le cookie et on redirige sur la bonne page - if ($existingUser["password"] == md5($_POST["password"])) { + if ($existingUser["password"] === md5($_POST["password"])) { $this->SetUser($existingUser, $_POST["remember"]); // si l'on veut utiliser la page d'accueil correspondant au nom d'utilisateur