ILIAS
Release_4_0_x_branch Revision 61816
|
Public Member Functions | |
Auth_Container_LDAP ($params) | |
Constructor of the container class. | |
_prepare () | |
Prepare LDAP connection. | |
_connect () | |
Connect to the LDAP server using the global options. | |
_disconnect () | |
Disconnects (unbinds) from ldap server. | |
_getBaseDN () | |
Tries to find Basedn via namingContext Attribute. | |
_isValidLink () | |
determines whether there is a valid ldap conenction or not | |
_setDefaults () | |
Set some default options. | |
_parseOptions ($array) | |
Parse options passed to the container class. | |
_setV12OptionsToV13 ($array) | |
Adapt deprecated options from Auth 1.2 LDAP to Auth 1.3 LDAP. | |
_scope2function ($scope) | |
Get search function for scope. | |
fetchData ($username, $password) | |
Fetch data from LDAP server. | |
checkGroup ($user) | |
Validate group membership. | |
_quoteFilterString ($filter_str) | |
Escapes LDAP filter special characters as defined in RFC 2254. | |
Public Member Functions inherited from Auth_Container | |
Auth_Container () | |
Constructor. | |
fetchData ($username, $password, $isChallengeResponse=false) | |
Fetch data from storage container. | |
verifyPassword ($password1, $password2, $cryptType="md5") | |
Crypt and verfiy the entered password. | |
supportsChallengeResponse () | |
Returns true if the container supports Challenge Response password authentication. | |
getCryptType () | |
Returns the crypt current crypt type of the container. | |
listUsers () | |
List all users that are available from the storage container. | |
getUser ($username) | |
Returns a user assoc array. | |
addUser ($username, $password, $additional=null) | |
Add a new user to the storage container. | |
removeUser ($username) | |
Remove user from the storage container. | |
changePassword ($username, $password) | |
Change password for user in the storage container. | |
log ($message, $level=AUTH_LOG_DEBUG) | |
Log a message to the Auth log. | |
Public Member Functions inherited from ilAuthContainerBase | |
loginObserver ($a_username, $a_auth) | |
Called after successful login. | |
failedLoginObserver ($a_username, $a_auth) | |
Called after failed login. | |
checkAuthObserver ($a_username, $a_auth) | |
Called after check auth requests. | |
logoutObserver ($a_username, $a_auth) | |
Called after logout. |
Data Fields | |
$options = array() | |
$conn_id = false | |
Data Fields inherited from Auth_Container | |
$activeUser = "" | |
User that is currently selected from the storage container. | |
$_auth_obj = null | |
The Auth object this container is attached to. |
Auth_Container_LDAP::_connect | ( | ) |
Connect to the LDAP server using the global options.
private
Definition at line 276 of file LDAP.php.
References _disconnect(), AUTH_LOG_DEBUG, Auth_Container\log(), and PEAR\raiseError().
Referenced by _prepare().
Auth_Container_LDAP::_disconnect | ( | ) |
Disconnects (unbinds) from ldap server.
private
Definition at line 349 of file LDAP.php.
References _isValidLink(), AUTH_LOG_DEBUG, and Auth_Container\log().
Referenced by _connect(), and fetchData().
Auth_Container_LDAP::_getBaseDN | ( | ) |
Tries to find Basedn via namingContext Attribute.
private
Definition at line 366 of file LDAP.php.
References $err, _isValidLink(), _prepare(), AUTH_LOG_DEBUG, Auth_Container\log(), and PEAR\raiseError().
Referenced by fetchData().
Auth_Container_LDAP::_isValidLink | ( | ) |
determines whether there is a valid ldap conenction or not
private
Definition at line 411 of file LDAP.php.
Referenced by _disconnect(), _getBaseDN(), and _prepare().
Auth_Container_LDAP::_parseOptions | ( | $array | ) |
Parse options passed to the container class.
private
array |
Definition at line 466 of file LDAP.php.
References $key, and _setV12OptionsToV13().
Referenced by Auth_Container_LDAP().
Auth_Container_LDAP::_prepare | ( | ) |
Prepare LDAP connection.
This function checks if we have already opened a connection to the LDAP server. If that's not the case, a new connection is opened.
private
Definition at line 256 of file LDAP.php.
References $res, _connect(), _isValidLink(), and PEAR\isError().
Referenced by _getBaseDN(), checkGroup(), and fetchData().
Auth_Container_LDAP::_quoteFilterString | ( | $filter_str | ) |
Escapes LDAP filter special characters as defined in RFC 2254.
private
string | Filter String |
Definition at line 755 of file LDAP.php.
Referenced by checkGroup(), and fetchData().
Auth_Container_LDAP::_scope2function | ( | $scope | ) |
Get search function for scope.
string | scope |
Definition at line 517 of file LDAP.php.
Referenced by checkGroup(), and fetchData().
Auth_Container_LDAP::_setDefaults | ( | ) |
Set some default options.
private
Definition at line 429 of file LDAP.php.
Referenced by Auth_Container_LDAP().
Auth_Container_LDAP::_setV12OptionsToV13 | ( | $array | ) |
Adapt deprecated options from Auth 1.2 LDAP to Auth 1.3 LDAP.
array |
Definition at line 496 of file LDAP.php.
Referenced by _parseOptions().
Auth_Container_LDAP::Auth_Container_LDAP | ( | $params | ) |
Constructor of the container class.
$params,associative | hash with host,port,basedn and userattr key |
Definition at line 230 of file LDAP.php.
References $params, _parseOptions(), _setDefaults(), PEAR_ERROR_DIE, and PEAR\raiseError().
Auth_Container_LDAP::checkGroup | ( | $user | ) |
Validate group membership.
Searches the LDAP server for group membership of the supplied username. Quotes all LDAP filter meta characters in the user name before querying the LDAP server.
string | Distinguished Name of the authenticated User |
Reimplemented in ilAuthContainerLDAP.
Definition at line 704 of file LDAP.php.
References $err, $filter, $user, _prepare(), _quoteFilterString(), _scope2function(), AUTH_LOG_DEBUG, Auth_Container\log(), and PEAR\raiseError().
Referenced by fetchData().
Auth_Container_LDAP::fetchData | ( | $username, | |
$password | |||
) |
Fetch data from LDAP server.
Searches the LDAP server for the given username/password combination. Escapes all LDAP meta characters in username before performing the query.
string | Username |
string | Password |
Reimplemented in ilAuthContainerLDAP.
Definition at line 547 of file LDAP.php.
References $err, $filter, $password, _disconnect(), _getBaseDN(), _prepare(), _quoteFilterString(), _scope2function(), AUTH_LOG_DEBUG, checkGroup(), elseif(), Auth_Container\log(), and PEAR\raiseError().