Zeta Components - high quality PHP components

Zeta Components Manual :: Docs For Class ezcAuthenticationLdapInfo

Authentication::ezcAuthenticationLdapInfo

Class ezcAuthenticationLdapInfo

Structure for defining the LDAP directory to authenticate against.

Source for this file: /Authentication/src/filters/ldap/ldap_info.php

ezcBaseStruct
   |
   --ezcAuthenticationLdapInfo
Version:   //autogen//

Member Variables

public string $base
The base of the directory entry, for example 'dc=example,dc=com'.
public string $format
The format of the directory entry, for example 'uid=%id'. %id% is a placeholder name which will be replaced by the actual value.
public string $host
The hostname of the LDAP server, for example 'localhost'.
public int $port
Port to connect to $host.

Default is 389 for plain connection. The port is 636 if using SSL (not implemented yet).

The port is not usable if $host is specified as an uri, for example 'ldap://localhost'.

public int $protocol
Protocol to use to connect to LDAP.

One of these values:

  • ezcAuthenticationLdapFilter::PROTOCOL_PLAIN (default)
  • ezcAuthenticationLdapFilter::PROTOCOL_TLS

Method Summary

public static ezcAuthenticationLdapInfo __set_state( $array )
Returns a new instance of this class with the data specified by $array.
public ezcAuthenticationLdapInfo __construct( $host , $format , $base , [ $port = 389] , [ $protocol = ezcAuthenticationLdapFilter::PROTOCOL_PLAIN] )
Constructs a new ezcAuthenticationLdapInfo object.

Methods

__set_state

static ezcAuthenticationLdapInfo __set_state( $array )

Returns a new instance of this class with the data specified by $array.

$array contains all the data members of this class in the form: array('member_name'=>value).

__set_state makes this class exportable with var_export. var_export() generates code, that calls this method when it is parsed with PHP.

Parameters:
Name Type Description
$array array(string=>mixed) Associative array of data members for this class

__construct

ezcAuthenticationLdapInfo __construct( string $host , string $format , string $base , [int $port = 389] , [int $protocol = ezcAuthenticationLdapFilter::PROTOCOL_PLAIN] )

Constructs a new ezcAuthenticationLdapInfo object.

Parameters:
Name Type Description
$host string Hostname of the LDAP server
$format string Format of an entry, for example 'uid=%id%'
$base string Base of an entry, for example 'dc=example,dc=com'
$port int The port to connect to $host
$protocol int The protocol to use to connect to $host
Documentation generated by phpDocumentor 1.4.3