Methods

Constructor

__construct(array $options, string $identity, string $credential) 

Parameters

$options

array

An array of arrays of Zend\Ldap\Ldap options

$identity

string

The username of the account being authenticated

$credential

string

The password of the account being authenticated

getAccountObject() - Returns the result entry as a stdClass object

getAccountObject(array $returnAttribs, array $omitAttribs) : \stdClass | bool

This resembles the feature {@see Zend\Authentication\Adapter\DbTable::getResultRowObject()}. Closes ZF-6813

Parameters

$returnAttribs

array

$omitAttribs

array

Returns

\stdClassbool

Returns the credential of the account being authenticated, or NULL if none is set.

getCredential() : mixed
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::getCredential()

Returns

mixed

Returns the identity of the account being authenticated, or NULL if none is set.

getIdentity() : mixed
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::getIdentity()

Returns

mixed

Returns the LDAP Object

getLdap() : \Zend\Ldap\Ldap

Returns

\Zend\Ldap\LdapThe Zend\Ldap\Ldap object used to authenticate the credentials

Returns the array of arrays of Zend\Ldap\Ldap options of this adapter.

getOptions() : array | null

Returns

arraynull

Returns the password of the account being authenticated, or NULL if none is set.

getPassword() : string | null

Returns

stringnull

Returns the username of the account being authenticated, or NULL if none is set.

getUsername() : string | null

Returns

stringnull

Sets the credential for binding

setCredential(mixed $credential) : \Zend\Authentication\Adapter\AbstractAdapter
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::setCredential()

Parameters

$credential

mixed

Returns

Sets the identity for binding

setIdentity(mixed $identity) : \Zend\Authentication\Adapter\AbstractAdapter
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::setIdentity()

Parameters

$identity

mixed

Returns

Set an Ldap connection

setLdap(\Zend\Ldap\Ldap $ldap) : \Zend\Authentication\Adapter\Ldap

Parameters

$ldap

\Zend\Ldap\Ldap

An existing Ldap object

Returns

\Zend\Authentication\Adapter\LdapProvides a fluent interface

Sets the array of arrays of Zend\Ldap\Ldap options to be used by this adapter.

setOptions(array $options) : \Zend\Authentication\Adapter\Ldap

Parameters

$options

array

The array of arrays of Zend\Ldap\Ldap options

Returns

\Zend\Authentication\Adapter\LdapProvides a fluent interface

Sets the password for the account

setPassword(string $password) : \Zend\Authentication\Adapter\Ldap

Parameters

$password

string

The password of the account being authenticated

Returns

\Zend\Authentication\Adapter\LdapProvides a fluent interface

Sets the username for binding

setUsername(string $username) : \Zend\Authentication\Adapter\Ldap

Parameters

$username

string

The username for binding

Returns

\Zend\Authentication\Adapter\LdapProvides a fluent interface

Checks the group membership of the bound user

checkGroupMembership(\Zend\Ldap\Ldap $ldap, string $canonicalName, string $dn, array $adapterOptions) : string | true

Parameters

$canonicalName

string

$dn

string

$adapterOptions

array

Returns

stringtrue

Returns a domain name for the current LDAP options.

getAuthorityName() : string

This is used for skipping redundant operations (e.g. authentications).

Returns

string

Sets the LDAP specific options on the Zend\Ldap\Ldap instance

prepareOptions(\Zend\Ldap\Ldap $ldap, array $options) : array

Parameters

$options

array

Returns

arrayof auth-adapter specific options

Converts options to string

optionsToString(array $options) : string

Parameters

$options

array

Returns

string

 Properties

 

The DN of the authenticated account.

$authenticatedDn : string

Used to retrieve the account entry on request.

 

$credential

$credential : mixed
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::$$credential
 

$identity

$identity : mixed
Inherited

inherited_from \Zend\Authentication\Adapter\AbstractAdapter::$$identity
 

The Zend\Ldap\Ldap context.

$ldap : \Zend\Ldap\Ldap

 

The array of arrays of Zend\Ldap\Ldap options passed to the constructor.

$options : array