Move Authorization and Authentication plugin structures into core, instead of as plugins.
This move makes sense as you can addPlugin('Authentication') for example - these are abstract classes designed to be implemented, not used directly.
This commit is contained in:
parent
f3a76bbcb7
commit
9e2e0605ed
@ -207,18 +207,6 @@ abstract class AuthenticationPlugin extends Plugin
|
||||
}
|
||||
}
|
||||
|
||||
function onAutoload($cls)
|
||||
{
|
||||
switch ($cls)
|
||||
{
|
||||
case 'User_username':
|
||||
require_once(INSTALLDIR.'/plugins/Authentication/User_username.php');
|
||||
return false;
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
function onCheckSchema() {
|
||||
$schema = Schema::get();
|
||||
$schema->ensureTable('user_username',
|
@ -66,9 +66,6 @@ abstract class AuthorizationPlugin extends Plugin
|
||||
}
|
||||
|
||||
//------------Below are the methods that connect StatusNet to the implementing Auth plugin------------\\
|
||||
function onInitializePlugin(){
|
||||
|
||||
}
|
||||
|
||||
function onStartSetUser(&$user) {
|
||||
$loginAllowed = $this->loginAllowed($user);
|
@ -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;
|
||||
|
@ -31,7 +31,6 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require_once INSTALLDIR.'/plugins/Authentication/AuthenticationPlugin.php';
|
||||
require_once 'Net/LDAP2.php';
|
||||
|
||||
class LdapAuthenticationPlugin extends AuthenticationPlugin
|
||||
|
@ -31,7 +31,6 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require_once INSTALLDIR.'/plugins/Authorization/AuthorizationPlugin.php';
|
||||
require_once 'Net/LDAP2.php';
|
||||
|
||||
class LdapAuthorizationPlugin extends AuthorizationPlugin
|
||||
|
@ -31,8 +31,6 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
|
||||
exit(1);
|
||||
}
|
||||
|
||||
require_once INSTALLDIR.'/plugins/Authentication/AuthenticationPlugin.php';
|
||||
|
||||
class ReverseUsernameAuthenticationPlugin extends AuthenticationPlugin
|
||||
{
|
||||
//---interface implementation---//
|
||||
|
Loading…
Reference in New Issue
Block a user