Class JAuthentication

Description

Authentication class, provides an interface for the Joomla authentication system

  • since: 11.1

Located in /libraries/joomla/user/authentication.php (line 39)

JObject
   |
   --JAuthentication
Class Constant Summary
Variable Summary
Method Summary
static array[JAuthenticationResponse] authorise (JAuthenticationResponse $response, [array $options = array()])
void attach (object $observer)
JAuthenticationResponse authenticate (array $credentials, [array $options = array()])
boolean detach (object $observer)
mixed getState ()
JAuthentication __construct ()
Variables
static JAuthentication $instance (line 114)
  • var: JAuthentication instances container.
  • since: 11.3
  • access: protected
array $_methods = array() (line 108)

A multi dimensional array of [function][] = key for observers

  • since: 11.1
  • access: protected
array $_observers = array() (line 92)

An array of Observer objects to notify

  • since: 11.1
  • access: protected
mixed $_state = null (line 100)

The state of the observable object

  • since: 11.1
  • access: protected

Inherited Variables

Inherited from JObject

JObject::$_errors
Methods
static method authorise (line 347)

Authorises that a particular user should be able to login

  • return: results of authorisation
  • since: 11.2
  • access: public
static array[JAuthenticationResponse] authorise (JAuthenticationResponse $response, [array $options = array()])
  • JAuthenticationResponse $response: response including username of the user to authorise
  • array $options: list of options
static method getInstance (line 139)

Returns the global authentication object, only creating it if it doesn't already exist.

  • return: The global JAuthentication object
  • since: 11.1
  • access: public
static JAuthentication getInstance ()
attach (line 170)

Attach an observer object

  • since: 11.1
  • access: public
void attach (object $observer)
  • object $observer: An observer object to attach
authenticate (line 276)

Finds out if a set of login credentials are valid by asking all observing objects to run their respective authentication routines.

  • return: Response object with status variable filled in for last plugin or first successful plugin.
  • see: JAuthenticationResponse
  • since: 11.1
  • access: public
JAuthenticationResponse authenticate (array $credentials, [array $options = array()])
  • array $credentials: Array holding the user credentials.
  • array $options: Array holding user options.
detach (line 238)

Detach an observer object

  • return: True if the observer object was detached.
  • since: 11.1
  • access: public
boolean detach (object $observer)
  • object $observer: An observer object to detach.
getState (line 156)

Get the state of the JAuthentication object

  • return: The state of the object.
  • since: 11.1
  • access: public
mixed getState ()
Constructor __construct (line 121)

Constructor

  • since: 11.1
  • access: public
JAuthentication __construct ()

Redefinition of:
JObject::__construct()
Class constructor, overridden in descendant classes.

Inherited Methods

Inherited From JObject

JObject::__construct()
JObject::def()
JObject::get()
JObject::getError()
JObject::getErrors()
JObject::getProperties()
JObject::set()
JObject::setError()
JObject::setProperties()
JObject::toString()
JObject::__toString()
Class Constants
STATUS_CANCEL = 2 (line 55)

Status to indicate cancellation of authentication (unused)

  • since: 11.2
STATUS_DENIED = 16 (line 77)

This is the status code returned when the account has been denied (prevent login)

  • since: 11.2
STATUS_EXPIRED = 8 (line 70)

This is the status code returned when the account has expired (prevent login)

  • since: 11.2
STATUS_FAILURE = 4 (line 62)

This is the status code returned when the authentication failed (prevent login if no success)

  • since: 11.2
STATUS_SUCCESS = 1 (line 47)

This is the status code returned when the authentication is success (permit login)

  • since: 11.2
STATUS_UNKNOWN = 32 (line 84)

This is the status code returned when the account doesn't exist (not an error)

  • since: 11.2

Documentation generated on Mon, 25 Jun 2012 13:52:28 -0500 by phpDocumentor 1.4.4