nieuws: support truncated dates in replies
[minimedit.git] / login / pass.inc.php
index 483f8bbb72aac517ea03d47f9a523a822e0aa404..cb2427e2babfdc0c77b6fd79b4b7de5099dbda95 100644 (file)
@@ -36,7 +36,8 @@ function passform($user, $input = [])
                return "Zorg dat bij de bevestiging precies het zelfde wachtwoord staat.";
        }
 
-       if (!file_put_contents($pwfile, $input['newpass'])) {
+       $passstore = password_hash($input['newpass'], PASSWORD_DEFAULT);
+       if (empty($passstore) or !file_put_contents($pwfile, $passstore)) {
                return "Het nieuwe wachtwoord kon niet worden opgeslagen. Het oude wachtwoord is behouden.";
        }