Public Member Functions | Protected Member Functions | Private Member Functions

ilAuthDB Class Reference

Authentication against ILIAS database. More...

Inheritance diagram for ilAuthDB:
Collaboration diagram for ilAuthDB:

Public Member Functions

 __construct ()
 Constructor.

Protected Member Functions

 loginObserver ($a_username)
 Called from base class after successful login.
 failedLoginObserver ()
 Called from base class after wrong login.

Private Member Functions

 setCallbacks ()
 Set callback function for PEAR Auth.

Detailed Description

Authentication against ILIAS database.

Author:
Stefan Meyer <smeyer.ilias@gmx.de>
Version:
$Id$

Definition at line 34 of file class.ilAuthDB.php.


Constructor & Destructor Documentation

ilAuthDB::__construct (  ) 

Constructor.

public

Definition at line 41 of file class.ilAuthDB.php.

References setCallbacks().

        {
                global $ilClientIniFile;
                
                $auth_params = array(
                                                'dsn'             => IL_DSN,
                                                'table'       => $ilClientIniFile->readVariable("auth", "table"),
                                                'usernamecol' => $ilClientIniFile->readVariable("auth", "usercol"),
                                                'passwordcol' => $ilClientIniFile->readVariable("auth", "passcol")
                                        );
                parent::Auth("DB", $auth_params,"",false);

                // Set callbacks
                $this->setCallbacks();
        }

Here is the call graph for this function:


Member Function Documentation

ilAuthDB::failedLoginObserver (  )  [protected]

Called from base class after wrong login.

protected

Parameters:
@return 

Definition at line 80 of file class.ilAuthDB.php.

        {
                return false;
        }

ilAuthDB::loginObserver ( a_username  )  [protected]

Called from base class after successful login.

Parameters:
string username

Definition at line 62 of file class.ilAuthDB.php.

References logout().

        {
                if(!strlen($_POST['password']))
                {
                        $this->status = AUTH_WRONG_LOGIN;
                        $this->logout();
                        return false;
                }
                return true;
        }

Here is the call graph for this function:

ilAuthDB::setCallbacks (  )  [private]

Set callback function for PEAR Auth.

Definition at line 89 of file class.ilAuthDB.php.

Referenced by __construct().

        {
                $this->setLoginCallback(array($this,'loginObserver'));
                $this->setFailedLoginCallback(array($this,'failedLoginObserver'));
        }

Here is the caller graph for this function:


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