From c2cae621e753b46d692cf9ece6ed1282cfe8b461 Mon Sep 17 00:00:00 2001 From: Roland Gruber Date: Tue, 31 Jul 2018 19:10:42 +0200 Subject: [PATCH] added salt for crypt --- lam/lib/account.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lam/lib/account.inc b/lam/lib/account.inc index 97b9844c..d43a17b9 100644 --- a/lam/lib/account.inc +++ b/lam/lib/account.inc @@ -150,7 +150,7 @@ function pwd_hash($password, $enabled = true, $hashType = 'SSHA') { $hash = ""; switch ($hashType) { case 'CRYPT': - $hash = "{CRYPT}" . crypt($password); + $hash = "{CRYPT}" . crypt($password, generateSalt(2)); break; case 'CRYPT-SHA512': $hash = "{CRYPT}" . crypt($password, '$6$' . generateSalt(16));