summaryrefslogtreecommitdiff
path: root/include/functions.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/functions.php')
-rw-r--r--include/functions.php13
1 files changed, 12 insertions, 1 deletions
diff --git a/include/functions.php b/include/functions.php
index d03fcfb15..f6ef7c2b3 100644
--- a/include/functions.php
+++ b/include/functions.php
@@ -547,7 +547,7 @@
if (!SINGLE_USER_MODE) {
$user_id = false;
- $modules = explode(",", AUTH_MODULES);
+ /* $modules = explode(",", AUTH_MODULES);
foreach ($modules as $module) {
$module_class = "auth_$module";
@@ -565,6 +565,17 @@
print T_sprintf("Fatal: authentication module %s not found.", $module);
die;
}
+ } */
+
+ global $pluginhost;
+ foreach ($pluginhost->get_hooks($pluginhost::HOOK_AUTH_USER) as $plugin) {
+
+ $user_id = (int) $plugin->authenticate($login, $password);
+
+ if ($user_id) {
+ $_SESSION["auth_module"] = strtolower(get_class($plugin));
+ break;
+ }
}
if ($user_id && !$check_only) {