summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2012-08-16 16:00:50 +0400
committerAndrew Dolgov <[email protected]>2012-08-16 16:00:50 +0400
commit200e0d4ebbd98da452c3eb120cb55b155764f614 (patch)
treef0a618dac101cf66d5fdcf25b996c33bc907d18a /include
parent1e666f0aeba4abfb6a9e4b555640bcb4859de066 (diff)
save module user authenticated with, only allow password change if module is 'internal'
Diffstat (limited to 'include')
-rw-r--r--include/functions.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/functions.php b/include/functions.php
index dfe48c596..a2e164416 100644
--- a/include/functions.php
+++ b/include/functions.php
@@ -693,7 +693,10 @@
$user_id = (int) $authenticator->authenticate($login, $password);
- if ($user_id) break;
+ if ($user_id) {
+ $_SESSION["auth_module"] = $module;
+ break;
+ }
} else {
print T_sprintf("Fatal: authentication module %s not found.", $module);
@@ -734,7 +737,6 @@
$_SESSION["hide_hello"] = true;
$_SESSION["hide_logout"] = true;
- $_SESSION["hide_change_password"] = true;
if (!$_SESSION["csrf_token"]) {
$_SESSION["csrf_token"] = sha1(uniqid(rand(), true));