From: Weblate Date: Fri, 26 Aug 2016 21:14:13 +0000 (+0200) Subject: Merge remote-tracking branch 'origin/master' X-Git-Tag: 1.2.0~24 X-Git-Url: https://git.p6c8.net/jirafeau_project.git/commitdiff_plain/007a65603bef02ac7eeccaebaa5c643fc69f031b?hp=d0cd7964b1b67033d2350994b8eb4dea324838cd Merge remote-tracking branch 'origin/master' --- diff --git a/admin.php b/admin.php index 62fd5ee..bfbd123 100644 --- a/admin.php +++ b/admin.php @@ -70,7 +70,8 @@ else /* Check classic admin password authentification. */ if (isset ($_POST['admin_password']) && empty($cfg['admin_http_auth_user'])) { - if ($cfg['admin_password'] === $_POST['admin_password']) + if ($cfg['admin_password'] === $_POST['admin_password'] || + $cfg['admin_password'] === hash('sha256', $_POST['admin_password'])) $_SESSION['admin_auth'] = true; else { diff --git a/install.php b/install.php index c537bdd..958aa1e 100644 --- a/install.php +++ b/install.php @@ -166,7 +166,7 @@ if (isset ($_POST['step']) && isset ($_POST['next'])) break; case 2: - $cfg['admin_password'] = $_POST['admin_password']; + $cfg['admin_password'] = hash('sha256', $_POST['admin_password']); jirafeau_export_cfg ($cfg); break;