Exldap v0.2.0 Exldap
Summary
Functions
Shutdown a connection to the LDAP server
Connects to a LDAP server using the settings defined in config.exs
Connects to a LDAP server using the arguments passed into the function
Open a connection to the LDAP server using the settings defined in config.exs
Open a connection to the LDAP server
Searches a LDAP entry and extracts an attribute based on the specified key, if the attribute does not exist returns nil
Searches for a LDAP entry, the base dn is obtained from the config.exs
Searches for a LDAP entry using the arguments passed into the function
Verify the credentials against a LDAP connection
Functions
Connects to a LDAP server using the settings defined in config.exs
Example
iex> Exldap.connect(timeout \\ :infinity)
{:ok, connection}
Or
{:error, error_description}
Connects to a LDAP server using the arguments passed into the function
Example
iex> Exldap.connect("SERVERADDRESS", 636, true, "CN=test123,OU=Accounts,DC=example,DC=com", "PASSWORD", timeout \\ :infinity)
{:ok, connection}
Or
{:error, error_description}
Open a connection to the LDAP server using the settings defined in config.exs
Example
iex> Exldap.open(timeout \\ :infinity)
{:ok, connection}
Or
{:error, error_description}
Open a connection to the LDAP server
Example
iex> Exldap.open("SERVERADDRESS", 636, true, timeout \\ :infinity)
{:ok, connection}
Or
{:error, error_description}
Searches a LDAP entry and extracts an attribute based on the specified key, if the attribute does not exist returns nil
Example
iex> Exldap.search_attributes(first_result, "displayName")
"Test User"
Searches for a LDAP entry, the base dn is obtained from the config.exs
Example
iex> Exldap.search_field(connection, "cn", "useraccount")
{:ok, search_results}
Searches for a LDAP entry using the arguments passed into the function
Example
iex> Exldap.search_field(connection, "OU=Accounts,DC=example,DC=com", "cn", "useraccount")
{:ok, search_results}