Marius Cramer
2014-08-14 f227fb72b50e8580cd5ec1f539ec5749de6dd48c
Support passwords in login that are crypted with crypt-SHA256
1 files modified
7 ■■■■■ changed files
interface/web/login/index.php 7 ●●●●● patch | view | raw | blame | history
interface/web/login/index.php
@@ -200,6 +200,13 @@
                                    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;
                                    }
                                } else {
                                    //* The password is md5 encrypted