PHP Класс sspmod_ldap_ConfigHelper, simplesamlphp

See the ldap-entry in config-templates/authsources.php for information about configuration of these options.
Показать файл Открыть проект

Открытые методы

Метод Описание
__construct ( array $config, string $location ) Constructor for this configuration parser.
getAttributes ( $dn, $attributes = null )
login ( string $username, string $password, array $sasl_args = null ) : array Attempt to log in using the given username and password.
searchfordn ( string | array $attribute, string $value, boolean $allowZeroHits ) : string Search for a DN.

Описание методов

__construct() публичный Метод

Constructor for this configuration parser.
public __construct ( array $config, string $location )
$config array Configuration.
$location string The location of this configuration. Used for error reporting.

getAttributes() публичный Метод

public getAttributes ( $dn, $attributes = null )

login() публичный Метод

Will throw a SimpleSAML_Error_Error('WRONGUSERPASS') if the username or password is wrong. If there is a configuration problem, an Exception will be thrown.
public login ( string $username, string $password, array $sasl_args = null ) : array
$username string The username the user wrote.
$password string The password the user wrote.
$sasl_args array Array of SASL options for LDAP bind.
Результат array Associative array with the users attributes.

searchfordn() публичный Метод

Search for a DN.
public searchfordn ( string | array $attribute, string $value, boolean $allowZeroHits ) : string
$attribute string | array The attribute name(s) searched for. If set to NULL, values from configuration is used.
$value string The attribute value searched for.
$allowZeroHits boolean Determines if the method will throw an exception if no hits are found. Defaults to FALSE.
Результат string The DN of the matching element, if found. If no element was found and $allowZeroHits is set to FALSE, an exception will be thrown; otherwise NULL will be returned.