diff --git a/security/Security.php b/security/Security.php index dbcf72a04..74acb4982 100644 --- a/security/Security.php +++ b/security/Security.php @@ -618,34 +618,6 @@ class Security extends Controller { return new ChangePasswordForm($this, 'ChangePasswordForm'); } - - /** - * Authenticate using the given email and password, returning the - * appropriate member object if - * - * @return bool|Member Returns FALSE if authentication fails, otherwise - * the member object - * @see setDefaultAdmin() - */ - public static function authenticate($RAW_email, $RAW_password) { - $SQL_email = Convert::raw2sql($RAW_email); - $SQL_password = Convert::raw2sql($RAW_password); - - // Default login (see {@setDetaultAdmin()}) - if(($RAW_email == self::$default_username) && ($RAW_password == self::$default_password) - && !empty(self::$default_username) && !empty(self::$default_password)) { - $member = self::findAnAdministrator(); - } else { - $member = DataObject::get_one("Member", "\"" . Member::get_unique_identifier_field() . "\" = '$SQL_email' AND \"Password\" IS NOT NULL"); - if($member && ($member->checkPassword($RAW_password) == false)) { - $member = null; - } - } - - return $member; - } - - /** * Return an existing member with administrator privileges, or create one of necessary. *