]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/CasAuthentication/CasAuthenticationPlugin.php
include changelog and version changes in text
[quix0rs-gnu-social.git] / plugins / CasAuthentication / CasAuthenticationPlugin.php
index 8f29c7d2adaf29e17d7de9952faed24b2a83a906..1662db3ebafab9fc03c31b0a8e9ea65bbb7de12b 100644 (file)
@@ -22,7 +22,7 @@
  * @category  Plugin
  * @package   StatusNet
  * @author    Craig Andrews <candrews@integralblue.com>
- * @copyright 2009 Craig Andrews http://candrews.integralblue.com
+ * @copyright 2009 Free Software Foundation, Inc http://www.fsf.org
  * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
  * @link      http://status.net/
  */
@@ -34,7 +34,6 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
 // We bundle the phpCAS library...
 set_include_path(get_include_path() . PATH_SEPARATOR . dirname(__FILE__) . '/extlib/CAS');
 
-require_once INSTALLDIR.'/plugins/Authentication/AuthenticationPlugin.php';
 class CasAuthenticationPlugin extends AuthenticationPlugin
 {
     public $server;
@@ -58,8 +57,6 @@ class CasAuthenticationPlugin extends AuthenticationPlugin
          case 'CasloginAction':
             require_once(INSTALLDIR.'/plugins/CasAuthentication/' . strtolower(mb_substr($cls, 0, -6)) . '.php');
             return false;
-         default:
-            return parent::onAutoload($cls);
         }
     }
 
@@ -140,5 +137,17 @@ class CasAuthenticationPlugin extends AuthenticationPlugin
         $casSettings['server']=$this->server;
         $casSettings['port']=$this->port;
         $casSettings['path']=$this->path;
+        $casSettings['takeOverLogin']=$this->takeOverLogin;
+    }
+
+    function onPluginVersion(&$versions)
+    {
+        $versions[] = array('name' => 'CAS Authentication',
+                            'version' => STATUSNET_VERSION,
+                            'author' => 'Craig Andrews',
+                            'homepage' => 'http://status.net/wiki/Plugin:CasAuthentication',
+                            'rawdescription' =>
+                            _m('The CAS Authentication plugin allows for StatusNet to handle authentication through CAS (Central Authentication Service).'));
+        return true;
     }
 }