Commit f227fb72 authored by Marius Cramer's avatar Marius Cramer
Browse files

Support passwords in login that are crypted with crypt-SHA256

parent 1bcc716d
......@@ -197,6 +197,13 @@ class login_index {
//* The password is crypt-md5 encrypted
$salt = '$1$'.substr($saved_password, 3, 8).'$';
if(crypt(stripslashes($passwort), $salt) != $saved_password) {
$user = false;
}
} elseif(substr($saved_password, 0, 3) == '$5$') {
//* The password is crypt-md5 encrypted
$salt = '$5$'.substr($saved_password, 3, 16).'$';
if(crypt(stripslashes($passwort), $salt) != $saved_password) {
$user = false;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment