Skip to content
Snippets Groups Projects
Commit 68408b09 authored by Peter Rotich's avatar Peter Rotich
Browse files

Implement authenticate at Staff/User authentication level

This allows SSO backends to ingore authenticate method
parent 02926ef4
No related branches found
No related tags found
No related merge requests found
...@@ -345,6 +345,10 @@ abstract class StaffAuthenticationBackend extends AuthenticationBackend { ...@@ -345,6 +345,10 @@ abstract class StaffAuthenticationBackend extends AuthenticationBackend {
return $staff; return $staff;
} }
function authenticate($username, $password) {
return false;
}
// Generic authentication key for staff's backend is the username // Generic authentication key for staff's backend is the username
protected function getAuthKey($staff) { protected function getAuthKey($staff) {
...@@ -418,6 +422,10 @@ abstract class UserAuthenticationBackend extends AuthenticationBackend { ...@@ -418,6 +422,10 @@ abstract class UserAuthenticationBackend extends AuthenticationBackend {
return true; return true;
} }
function authenticate($username, $password) {
return false;
}
static function signOut($user) { static function signOut($user) {
global $ost; global $ost;
...@@ -736,10 +744,6 @@ class AuthTokenAuthentication extends UserAuthenticationBackend { ...@@ -736,10 +744,6 @@ class AuthTokenAuthentication extends UserAuthenticationBackend {
return $user; return $user;
} }
function authenticate($username, $password) {
return false;
}
} }
UserAuthenticationBackend::register(AuthTokenAuthentication); UserAuthenticationBackend::register(AuthTokenAuthentication);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment