aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/pam.php
diff options
context:
space:
mode:
Diffstat (limited to 'engine/lib/pam.php')
-rw-r--r--engine/lib/pam.php39
1 files changed, 0 insertions, 39 deletions
diff --git a/engine/lib/pam.php b/engine/lib/pam.php
index 308d4d291..e335b7e52 100644
--- a/engine/lib/pam.php
+++ b/engine/lib/pam.php
@@ -72,42 +72,3 @@ function unregister_pam_handler($handler, $policy = "user") {
unset($_PAM_HANDLERS[$policy][$handler]);
}
-function pam_authenticate($credentials = NULL, $policy = "user") {
- elgg_deprecated_notice('pam_authenticate has been deprecated for ElggPAM', 1.8);
- global $_PAM_HANDLERS, $_PAM_HANDLERS_MSG;
-
- $_PAM_HANDLERS_MSG = array();
-
- $authenticated = false;
-
- foreach ($_PAM_HANDLERS[$policy] as $k => $v) {
- $handler = $v->handler;
- $importance = $v->importance;
-
- try {
- // Execute the handler
- if ($handler($credentials)) {
- // Explicitly returned true
- $_PAM_HANDLERS_MSG[$k] = "Authenticated!";
-
- $authenticated = true;
- } else {
- $_PAM_HANDLERS_MSG[$k] = "Not Authenticated.";
-
- // If this is required then abort.
- if ($importance == 'required') {
- return false;
- }
- }
- } catch (Exception $e) {
- $_PAM_HANDLERS_MSG[$k] = "$e";
-
- // If this is required then abort.
- if ($importance == 'required') {
- return false;
- }
- }
- }
-
- return $authenticated;
-}