PHP Interface Adldap\Auth\GuardInterface

Show file Open project: adldap2/adldap2

Public Methods

Method Description
__construct ( Adldap\Connections\ConnectionInterface $connection, DomainConfiguration $configuration ) Constructor.
attempt ( string $username, string $password, boolean $bindAsUser = false ) : boolean Authenticates a user using the specified credentials.
bind ( string $username, string $password, string $prefix = null, string $suffix = null ) Binds to the current connection using the inserted credentials.
bindAsAdministrator ( ) Binds to the current LDAP server using the configuration administrator credentials.

Method Details

__construct() public method

Constructor.
public __construct ( Adldap\Connections\ConnectionInterface $connection, DomainConfiguration $configuration )
$connection Adldap\Connections\ConnectionInterface
$configuration Adldap\Configuration\DomainConfiguration

attempt() public method

Authenticates a user using the specified credentials.
public attempt ( string $username, string $password, boolean $bindAsUser = false ) : boolean
$username string The users AD username.
$password string The users AD password.
$bindAsUser boolean Whether or not to bind as the user.
return boolean

bind() public method

Binds to the current connection using the inserted credentials.
public bind ( string $username, string $password, string $prefix = null, string $suffix = null )
$username string
$password string
$prefix string
$suffix string

bindAsAdministrator() public method

Binds to the current LDAP server using the configuration administrator credentials.
public bindAsAdministrator ( )