Documentation

Horde_Block_Account_Ldap extends Horde_Block_Account_Base
in package

The ldap class attempts to return user information stored in an ldap directory service.

Copyright 2001-2017 Horde LLC (http://www.horde.org/)

See the enclosed file LICENSE for license information (LGPL-2). If you did not receive this file, see http://www.horde.org/licenses/lgpl.

Tags
author

Eric Jon Rostetter eric.rostetter@physics.utexas.edu

author

Jan Schneider jan@horde.org

Table of Contents

$_information  : array<string|int, mixed>
User information hash.
$_ldap  : Horde_Ldap
Pointer to the LDAP connection.
$_params  : array<string|int, mixed>
Hash containing connection parameters.
__construct()  : mixed
Constructor.
checkPasswordStatus()  : string
Returns the status of the current password.
getFullname()  : string
Returns the user's full name.
getHome()  : string
Returns the user's home (login) directory.
getPasswordChange()  : string
Returns the date of the user's last password change.
getQuota()  : array<string|int, mixed>
Returns the user's quota if available.
getShell()  : string
Returns the user's default shell.
getUsername()  : string
Returns the username.
_convertWinTimeToUnix()  : int
Code from 'brudinie at yahoo dot co dot uk' at http://nl3.php.net/ldap/
_getAccount()  : Horde_Ldap_Entry
Returns the user account from the LDAP source.
_getMaxPasswd()  : int|bool
Returns the win32 AD epoch number of days the password may be unchanged.

Properties

$_information

User information hash.

protected array<string|int, mixed> $_information

$_ldap

Pointer to the LDAP connection.

protected Horde_Ldap $_ldap

$_params

Hash containing connection parameters.

protected array<string|int, mixed> $_params = array()

Methods

__construct()

Constructor.

public __construct([array<string|int, mixed> $params = array() ]) : mixed
Parameters
$params : array<string|int, mixed> = array()

A hash containing connection parameters.

Return values
mixed

checkPasswordStatus()

Returns the status of the current password.

public checkPasswordStatus() : string
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
string

A string with a warning message if the password is about to expire.

getFullname()

Returns the user's full name.

public getFullname() : string
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
string

The user's full name.

getHome()

Returns the user's home (login) directory.

public getHome() : string
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
string

The user's directory.

getPasswordChange()

Returns the date of the user's last password change.

public getPasswordChange() : string
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
string

Date string.

getQuota()

Returns the user's quota if available.

public getQuota() : array<string|int, mixed>
Return values
array<string|int, mixed>

A quota array, elements are used bytes and limit bytes.

getShell()

Returns the user's default shell.

public getShell() : string
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
string

The user's shell.

getUsername()

Returns the username.

public getUsername() : string
Return values
string

The lowercased username.

_convertWinTimeToUnix()

Code from 'brudinie at yahoo dot co dot uk' at http://nl3.php.net/ldap/

protected _convertWinTimeToUnix(int $dateLargeInt) : int
Parameters
$dateLargeInt : int

The win32 active directory epoch time.

Return values
int

A unix timestamp.

_getAccount()

Returns the user account from the LDAP source.

protected _getAccount() : Horde_Ldap_Entry
Tags
throws
Horde_Exception

if user not found.

throws
Horde_Ldap_Exception

on LDAP errors.

Return values
Horde_Ldap_Entry

An entry with complete account details.

_getMaxPasswd()

Returns the win32 AD epoch number of days the password may be unchanged.

protected _getMaxPasswd() : int|bool
Return values
int|bool

Number of days or false if no limit.

Search results