SAuthModule Class Reference

Base authentication module class for realm-specific auth modules to extend. More...

Inheritance diagram for SAuthModule:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 authenticate ($username, $password)
 Attempt to authenticate this module with a username and password.
 getPermissions ()
 Get any special permissions associated with this user.
 getRole ()
 Get the role of the authenticated user.


Detailed Description

Base authentication module class for realm-specific auth modules to extend.

Author:
Joel/Jonathan (jfeiner/jwsm)
Date:
11/29/2007

Member Function Documentation

SAuthModule::authenticate ( username,
password 
) [abstract]

Attempt to authenticate this module with a username and password.

Parameters:
$username [string]: The username to use when authenticating
$password [string]: The password to use when authenticating
Returns:
[bool]: True if authentication worked, false if not, null if error
In a particular authentication module, this function should connect to the project database, LDAP server, etc., verify the user, and then set the attributes of this object from the (first) matching user record that is found.

Reimplemented in SLdap, and SLdapAuthModule.

SAuthModule::getPermissions (  )  [abstract]

Get any special permissions associated with this user.

Returns:
[mixed]: False if there are no extra permissions

Reimplemented in SLdap, and SLdapAuthModule.

SAuthModule::getRole (  )  [abstract]

Get the role of the authenticated user.

Returns:
[mixed]: A string containing the role if one is set; null otherwise (including if the user is not authenticated)
A role is a name representing a user's set of permissions within a given project. For instance, "admin," "user," or "staff" could be roles signifying different abilities to perform actions.

Reimplemented in SLdap, and SLdapAuthModule.


The documentation for this class was generated from the following file:

Generated on Wed Nov 24 02:02:31 2010 for Common by  doxygen 1.5.6