adLDAP - LDAP authentication with PHP for Active Directory

SourceForge.net Logo

Overloading

The configuration options declared in adLDAP itself are protected variables. That means they cannot be set from directly outside the class. You have always been able to set them at run time by passing an array to the adLDAP constructor.

However adLDAP allows overloading of certain objects. This allows you to set and retrieve some of the protected settings and are not visible to your code from outside the class.

This can include wanting to disconnect, change the authentication details and re-connect without having to reinstantiate the adLDAP class.

See the configuration settings for information about what these settings mean.

setAccountSuffix($accountSuffix)

Allows you to set the full account suffix for your domain.

getAccountSuffix()

Returns the current full account suffix for your domain.

setDomainControllers(array $domainControllers)

Set the array of domain controllers available to adLDAP. You might want to use this function if you wish to connect to one domain controller for a certain purpose, disconnect and then connect to a totally different domain controller to perform a different task.

getDomainControllers()

Returns the current array of domain controllers.

setAdminUsername($adminUsername)

Set the Active Directory username for an account with higher priviledges than the currently authenticated user

getAdminUsername()

Calling this function will throw an adLDAPException as we do not expose any defined usernames for security reasons

setAdminPassword($adminPassword)

Set the Active Directory password for an account with higher priviledges than the currently authenticated user

getAdminPassword()

Calling this function will throw an adLDAPException as we do not expose any defined passwords for security reasons

setRealPrimaryGroup($realPrimaryGroup)

Set a boolean value for whether to return the real primary group of a user account

getRealPrimaryGroup()

Returns the current setting

setUseSSL($useSSL)

Set a boolean value for whether to return connect over SSL to the Domain Controller. Setting this to true will automatically change the default port to the SSL port number

getUseSSL()

Returns the current setting

setUseTLS($useTLS)

Set a boolean value for whether to return connect over TLS to the Domain Controller

getUseTLS()

Returns the current setting

setRecursiveGroups($recursiveGroups)

Set a boolean value for whether to when querying group memberships, do it recursively

getRecursiveGroups()

Returns the current setting

setPort($adPort)

An integer that sets the current port number for the domain controller. Two predefined constants exist

adLDAP::ADLDAP_LDAP_PORT
adLDAP::ADLDAP_LDAPS_PORT

getPort()

Returns the current setting

 
documentation_overloading.txt · Last modified: 2012/08/22 10:00 by rich2000
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki