removed mods directory from the ATutor codebase
[atutor.git] / mods / wiki / plugins / auth / userdb_xprofile.php
diff --git a/mods/wiki/plugins/auth/userdb_xprofile.php b/mods/wiki/plugins/auth/userdb_xprofile.php
deleted file mode 100644 (file)
index fc5a689..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-<?php
-/*
-   Allows access using XML User Profiles (XUP/XProfile). Requires $_SESSION support.
-*/
-
-#-- init hack (runs slow without)
-if (!constant("SESSION_ID") && !session_id()) { 
-   session_start();
-}
-
-
-$ewiki_plugins["auth_userdb"][] = "ewiki_auth_userdb_xprofile";
-
-function ewiki_auth_userdb_xprofile($username, $password) {
-   global $ewiki_author;
-   
-   #-- already logged in
-   if ($_SESSION["xprofile"]) {
-      $ewiki_author = $_SESSION["ewiki_author"];
-      return($true);
-   }
-
-   #-- fetch profile
-   $xpro = new xprofile($username);  // URL or email-like shortcut
-   if ($xpro->control) {
-  
-      #-- validate
-      if ($xpro->login() ) {
-      
-         #-- save data
-         $_SESSION["ewiki_author"] = $ewiki_author = $xpro->info["nickname"];
-         $_SESSION["xprofile"] = $xpro->url;
-      
-         return(true);
-      }
-      else {
-         // misuse (already logged by XProfile manager)
-         ewiki_log("userdb_xprofile: wrong password '...' for remote account on '$username'", 1);
-      }
-   }
-
-   return(false);   
-}
-
-?>
\ No newline at end of file