LdapClient
class LdapClient implements LdapClientInterface
Methods
| __construct(string $host = null, int $port = 389, int $version = 3, bool $useSsl = false, bool $useStartTls = false, bool $optReferrals = false) Constructor. | ||
| __destruct() | ||
| bind(string $dn = null, string $password = null) Return a connection bound to the ldap. | ||
| find($dn, $query, $filter = '*') | ||
| string | escape(string $subject, string $ignore = '', int $flags) Escape a string for use in an LDAP filter or DN. |
Details
__construct(string $host = null, int $port = 389, int $version = 3, bool $useSsl = false, bool $useStartTls = false, bool $optReferrals = false)
Constructor.
Parameters
| string | $host | |
| int | $port | |
| int | $version | |
| bool | $useSsl | |
| bool | $useStartTls | |
| bool | $optReferrals |
__destruct()
bind(string $dn = null, string $password = null)
Return a connection bound to the ldap.
Parameters
| string | $dn | A LDAP dn |
| string | $password | A password |
Exceptions
| ConnectionException | If dn / password could not be bound. |
find($dn, $query, $filter = '*')
Parameters
| $dn | ||
| $query | ||
| $filter |
string escape(string $subject, string $ignore = '', int $flags)
Escape a string for use in an LDAP filter or DN.
Parameters
| string | $subject | |
| string | $ignore | |
| int | $flags |
Return Value
| string |
© 2004–2017 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/3.0/Symfony/Component/Ldap/LdapClient.html