Liblinphone  5.3.0
Typedefs | Enumerations | Functions
Ldap

Typedefs

typedef struct _LinphoneLdap LinphoneLdap
 Object that represents a Linphone Ldap. More...
 
typedef struct _LinphoneLdapParams LinphoneLdapParams
 Object that is used to set the different parameters of a LinphoneLdap.
 
typedef enum _LinphoneLdapDebugLevel LinphoneLdapDebugLevel
 Enum Debug verbosity for OpenLdap.
 
typedef enum _LinphoneLdapAuthMethod LinphoneLdapAuthMethod
 Enum describing how the authentification will be made.
 
typedef enum _LinphoneLdapCertVerificationMode LinphoneLdapCertVerificationMode
 Enum describing server certificates verification modes.
 
typedef enum _LinphoneLdapCheck LinphoneLdapCheck
 Enum describing errors in LDAP parameters.
 

Enumerations

enum  _LinphoneLdapDebugLevel {
  LinphoneLdapDebugLevelOff = 0,
  LinphoneLdapDebugLevelVerbose = 1
}
 Enum Debug verbosity for OpenLdap. More...
 
enum  _LinphoneLdapAuthMethod {
  LinphoneLdapAuthMethodAnonymous = 0,
  LinphoneLdapAuthMethodSimple = 1
}
 Enum describing how the authentification will be made. More...
 
enum  _LinphoneLdapCertVerificationMode {
  LinphoneLdapCertVerificationDefault = -1,
  LinphoneLdapCertVerificationDisabled = 0,
  LinphoneLdapCertVerificationEnabled = 1
}
 Enum describing server certificates verification modes. More...
 
enum  _LinphoneLdapCheck {
  LinphoneLdapCheckOk = 0,
  LinphoneLdapCheckServerEmpty = 1,
  LinphoneLdapCheckServerNotUrl = 2,
  LinphoneLdapCheckServerNoScheme = 4,
  LinphoneLdapCheckServerNotLdap = 8,
  LinphoneLdapCheckServerLdaps,
  LinphoneLdapCheckBaseObjectEmpty = 32,
  LinphoneLdapCheckMissingFields = 64
}
 Enum describing errors in LDAP parameters. More...
 

Functions

LinphoneLdapParamslinphone_core_create_ldap_params (LinphoneCore *core)
 Create a LDAP params using default values from Linphone core. More...
 
LinphoneLdaplinphone_core_create_ldap (LinphoneCore *core)
 Create an empty LDAP search. More...
 
LinphoneLdaplinphone_core_create_ldap_with_params (LinphoneCore *core, LinphoneLdapParams *params)
 Create a LDAP search using given parameters and store them in the configuration file. More...
 
void linphone_core_clear_ldaps (LinphoneCore *core)
 Erase all LDAP from the configuration. More...
 
void linphone_core_add_ldap (LinphoneCore *core, LinphoneLdap *ldap)
 Add or update a LDAP server and save it to the configuration. More...
 
void linphone_core_remove_ldap (LinphoneCore *core, LinphoneLdap *ldap)
 Remove a LDAP from the configuration. More...
 
bctbx_list_t * linphone_core_get_ldap_list (LinphoneCore *core)
 Returns a list of entered LDAPs. More...
 
bool_t linphone_core_get_chat_messages_aggregation_enabled (LinphoneCore *core)
 Returns whether chat messages grouping is enabled or not. More...
 
void linphone_core_set_chat_messages_aggregation_enabled (LinphoneCore *core, bool_t enabled)
 Sets whether chat messages grouping is enabled or not. More...
 
LinphoneStatus linphone_core_config_sync (LinphoneCore *core)
 Writes the config file to disk. More...
 
const LinphonePushNotificationConfiglinphone_core_get_push_notification_config (const LinphoneCore *core)
 Gets the push notification configuration object if it exists. More...
 
const bctbx_list_t * linphone_core_get_loaded_plugins (LinphoneCore *core)
 Return the list of loaded plugins. More...
 
bool_t linphone_core_is_plugin_loaded (const LinphoneCore *core, const char *name)
 Tells whether a plugin is loaded or not. More...
 
MS2_DEPRECATED int linphone_core_get_conference_size (LinphoneCore *core)
 Get the number of participants including me, if it in, in the running conference. More...
 
MS2_DEPRECATED LinphoneConferencelinphone_core_get_conference (LinphoneCore *core)
 Get a pointer on the internal conference object. More...
 
LinphoneLdaplinphone_ldap_new (LinphoneCore *lc)
 Create a new LinphoneLdap. More...
 
LinphoneLdaplinphone_ldap_new_with_params (LinphoneCore *lc, LinphoneLdapParams *params)
 Create a new LinphoneLdap, associate it with the LinphoneLdapParams and store it into the configuration file. More...
 
LinphoneLdaplinphone_ldap_ref (LinphoneLdap *ldap)
 Take a reference on a LinphoneLdap. More...
 
void linphone_ldap_unref (LinphoneLdap *ldap)
 Release a LinphoneLdap. More...
 
void linphone_ldap_set_params (LinphoneLdap *ldap, LinphoneLdapParams *params)
 Set the LinphoneLdapParams used by this LinphoneLdap. More...
 
const LinphoneLdapParamslinphone_ldap_get_params (LinphoneLdap *ldap)
 Get the LinphoneLdapParams as read-only object. More...
 
LinphoneCorelinphone_ldap_get_core (LinphoneLdap *ldap)
 Get the LinphoneCore object to which is associated the LinphoneLdap. More...
 
void linphone_ldap_set_index (LinphoneLdap *ldap, int index)
 Set the index associated to the LinphoneLdap. More...
 
int linphone_ldap_get_index (const LinphoneLdap *ldap)
 Get the index of the LinphoneLdap. More...
 
LinphoneLdapParamslinphone_ldap_params_new (LinphoneCore *lc)
 Create a new LinphoneLdapParams object. More...
 
LinphoneLdapParamslinphone_ldap_params_clone (const LinphoneLdapParams *params)
 Instantiate a new LinphoneLdapParams with values from source. More...
 
LinphoneLdapParamslinphone_ldap_params_ref (LinphoneLdapParams *params)
 Take a reference on a LinphoneLdapParams. More...
 
void linphone_ldap_params_unref (LinphoneLdapParams *params)
 Release a LinphoneLdapParams. More...
 
void linphone_ldap_params_set_custom_value (LinphoneLdapParams *params, const char *key, const char *value)
 Set custom field. More...
 
const char * linphone_ldap_params_get_custom_value (const LinphoneLdapParams *params, const char *key)
 Get the value from field. More...
 
void linphone_ldap_params_set_server (LinphoneLdapParams *params, const char *server)
 LDAP Server. More...
 
const char * linphone_ldap_params_get_server (const LinphoneLdapParams *params)
 Get the LDAP Server. More...
 
void linphone_ldap_params_set_bind_dn (LinphoneLdapParams *params, const char *bind_dn)
 Bind DN to use for bindings. More...
 
const char * linphone_ldap_params_get_bind_dn (const LinphoneLdapParams *params)
 Get the Bind DN to use for bindings. More...
 
void linphone_ldap_params_set_base_object (LinphoneLdapParams *params, const char *base_object)
 BaseObject is a specification for LDAP Search Scopes that specifies that the Search Request should only be performed against the entry specified as the search base DN. More...
 
const char * linphone_ldap_params_get_base_object (const LinphoneLdapParams *params)
 Get the BaseObject. More...
 
void linphone_ldap_params_set_timeout (LinphoneLdapParams *params, int timeout)
 Timeout for requests in seconds. More...
 
int linphone_ldap_params_get_timeout (const LinphoneLdapParams *params)
 Get the timeout for requests in seconds. More...
 
void linphone_ldap_params_set_timeout_tls_ms (LinphoneLdapParams *params, int timeout)
 Timeout for TLS connection in milliseconds. More...
 
int linphone_ldap_params_get_timeout_tls_ms (const LinphoneLdapParams *params)
 Get the timeout for TLS connection in milliseconds. More...
 
void linphone_ldap_params_set_max_results (LinphoneLdapParams *params, int max_results)
 The max results when requesting searches. More...
 
int linphone_ldap_params_get_max_results (const LinphoneLdapParams *params)
 Get the max results when requesting searches. More...
 
void linphone_ldap_params_set_min_chars (LinphoneLdapParams *params, int min_chars)
 The minimum characters needed for doing a search on LDAP servers. More...
 
int linphone_ldap_params_get_min_chars (const LinphoneLdapParams *params)
 Get the minimum characters needed for doing a search on LDAP servers. More...
 
void linphone_ldap_params_set_delay (LinphoneLdapParams *params, int delay)
 Delay between each search in milliseconds Default value : 500. More...
 
int linphone_ldap_params_get_delay (const LinphoneLdapParams *params)
 Get the delay between each search in milliseconds. More...
 
void linphone_ldap_params_set_auth_method (LinphoneLdapParams *params, LinphoneLdapAuthMethod auth_method)
 Authentification method. More...
 
LinphoneLdapAuthMethod linphone_ldap_params_get_auth_method (const LinphoneLdapParams *params)
 Get the authentification method. More...
 
void linphone_ldap_params_set_password (LinphoneLdapParams *params, const char *password)
 The password to pass to server when binding. More...
 
const char * linphone_ldap_params_get_password (const LinphoneLdapParams *params)
 Get the password to pass to server when binding. More...
 
void linphone_ldap_params_set_filter (LinphoneLdapParams *params, const char *filter)
 The search is based on this filter to search contacts. More...
 
const char * linphone_ldap_params_get_filter (const LinphoneLdapParams *params)
 Get the search is based on this filter to search contacts. More...
 
void linphone_ldap_params_set_name_attribute (LinphoneLdapParams *params, const char *name_attribute)
 Check these attributes to build Name Friend, separated by a comma and the first is the highest priority. More...
 
const char * linphone_ldap_params_get_name_attribute (const LinphoneLdapParams *params)
 Get the attributes to build Name Friend, separated by a comma and the first is the highest priority. More...
 
void linphone_ldap_params_set_sip_attribute (LinphoneLdapParams *params, const char *sip_attribute)
 Check these attributes to build the SIP username in address of Friend. More...
 
const char * linphone_ldap_params_get_sip_attribute (const LinphoneLdapParams *params)
 Get the attributes to build the SIP username in address of Friend. More...
 
void linphone_ldap_params_set_sip_domain (LinphoneLdapParams *params, const char *sip_domain)
 Add the domain to the sip address(sip:username). More...
 
const char * linphone_ldap_params_get_sip_domain (const LinphoneLdapParams *param)
 Get the domain to the sip address(sip:username). More...
 
void linphone_ldap_params_set_enabled (LinphoneLdapParams *params, bool_t enable)
 If this config is enabled. More...
 
bool_t linphone_ldap_params_get_enabled (const LinphoneLdapParams *params)
 Return if the configuration is enabled. More...
 
void linphone_ldap_params_enable_sal (LinphoneLdapParams *params, bool_t enable)
 The dns resolution is done by Linphone using Sal. More...
 
bool_t linphone_ldap_params_sal_enabled (const LinphoneLdapParams *params)
 Return if the dns resolution is done by Linphone using Sal. More...
 
void linphone_ldap_params_enable_tls (LinphoneLdapParams *params, bool_t enable)
 Encrypt transactions by LDAP over TLS(StartTLS). More...
 
bool_t linphone_ldap_params_tls_enabled (const LinphoneLdapParams *params)
 Return if transactions are encrypted by LDAP over TLS(StartTLS). More...
 
void linphone_ldap_params_set_debug_level (LinphoneLdapParams *params, LinphoneLdapDebugLevel level)
 The debug verbosity level from internal LDAP API. More...
 
LinphoneLdapDebugLevel linphone_ldap_params_get_debug_level (const LinphoneLdapParams *params)
 Return the debug verbosity level. More...
 
void linphone_ldap_params_set_server_certificates_verification_mode (LinphoneLdapParams *params, LinphoneLdapCertVerificationMode verify_server_certificates)
 Specify whether the tls server certificate must be verified when connecting to a LDAP server. More...
 
LinphoneLdapCertVerificationMode linphone_ldap_params_get_server_certificates_verification_mode (const LinphoneLdapParams *params)
 Return whether the tls server certificate must be verified when connecting to a LDAP server. More...
 
int linphone_ldap_params_check (const LinphoneLdapParams *params)
 Check parameters and return what are wrong. More...
 

Detailed Description

Typedef Documentation

◆ LinphoneLdap

typedef struct _LinphoneLdap LinphoneLdap

Object that represents a Linphone Ldap.

Use a LinphoneLdapParams object to configure it.

Enumeration Type Documentation

◆ _LinphoneLdapAuthMethod

Enum describing how the authentification will be made.

Enumerator
LinphoneLdapAuthMethodAnonymous 

Connection without passwords.

LinphoneLdapAuthMethodSimple 

Connection with username/password.

◆ _LinphoneLdapCertVerificationMode

Enum describing server certificates verification modes.

Enumerator
LinphoneLdapCertVerificationDefault 

Use default value defined on core.

LinphoneLdapCertVerificationDisabled 

Verification is disabled.

LinphoneLdapCertVerificationEnabled 

Verification is enabled.

◆ _LinphoneLdapCheck

Enum describing errors in LDAP parameters.

Enumerator
LinphoneLdapCheckOk 

No error.

LinphoneLdapCheckServerEmpty 

Server field is empty.

LinphoneLdapCheckServerNotUrl 

The server is not an url.

LinphoneLdapCheckServerNoScheme 

The server doesn't contain a scheme.

LinphoneLdapCheckServerNotLdap 

The server is not a LDAP scheme.

LinphoneLdapCheckServerLdaps 

LDAP over SSL is non-standardized and deprecated: ldaps has been specified.

LinphoneLdapCheckBaseObjectEmpty 

Base Object has been specified.

LinphoneLdapCheckMissingFields 

Some required fields are missing.

◆ _LinphoneLdapDebugLevel

Enum Debug verbosity for OpenLdap.

Enumerator
LinphoneLdapDebugLevelOff 

Set OpenLdap verbosity to none.

LinphoneLdapDebugLevelVerbose 

Set OpenLdap verbosity to debug level.

Function Documentation

◆ linphone_core_add_ldap()

void linphone_core_add_ldap ( LinphoneCore core,
LinphoneLdap ldap 
)

Add or update a LDAP server and save it to the configuration.

Parameters
coreLinphoneCore object
ldapThe LDAP to add/update.

◆ linphone_core_clear_ldaps()

void linphone_core_clear_ldaps ( LinphoneCore core)

Erase all LDAP from the configuration.

Parameters
coreLinphoneCore object

◆ linphone_core_config_sync()

LinphoneStatus linphone_core_config_sync ( LinphoneCore core)

Writes the config file to disk.

Parameters
coreThe LinphoneCore object
Returns
0 if successful, -1 otherwise

◆ linphone_core_create_ldap()

LinphoneLdap* linphone_core_create_ldap ( LinphoneCore core)

Create an empty LDAP search.

linphone_ldap_set_params() must be call to save the parameters in the configuration file.

Parameters
coreLinphoneCore object
paramsLinphoneLdapParams object
Returns
LinphoneLdap with default values set

◆ linphone_core_create_ldap_params()

LinphoneLdapParams* linphone_core_create_ldap_params ( LinphoneCore core)

Create a LDAP params using default values from Linphone core.

Check #linphone_ldap_params to update values. In order to add a new LDAP configuration to Magic search, these parameters must be passed to linphone_core_create_ldap_with_params. Or, use linphone_ldap_set_params().

The newly created LDAP from linphone_core_create_ldap().

Parameters
coreLinphoneCore object
Returns
LinphoneLdapParams with default values set.

◆ linphone_core_create_ldap_with_params()

LinphoneLdap* linphone_core_create_ldap_with_params ( LinphoneCore core,
LinphoneLdapParams params 
)

Create a LDAP search using given parameters and store them in the configuration file.

Parameters
coreLinphoneCore object
paramsLinphoneLdapParams object
Returns
LinphoneLdap with default values set

◆ linphone_core_get_chat_messages_aggregation_enabled()

bool_t linphone_core_get_chat_messages_aggregation_enabled ( LinphoneCore core)

Returns whether chat messages grouping is enabled or not.

Parameters
coreThe LinphoneCore object
Returns
TRUE if received chat messages will be notified as a bundle, FALSE otherwise.

◆ linphone_core_get_conference()

MS2_DEPRECATED LinphoneConference* linphone_core_get_conference ( LinphoneCore core)

Get a pointer on the internal conference object.

Parameters
coreLinphoneCore
Returns
A pointer on LinphoneConference or NULL if no conference are going on.
Deprecated:
10/08/2023 Use linphone_core_search_conference() instead.

◆ linphone_core_get_conference_size()

MS2_DEPRECATED int linphone_core_get_conference_size ( LinphoneCore core)

Get the number of participants including me, if it in, in the running conference.

The local participant is included in the count only if it is in the conference.

Parameters
coreLinphoneCore
Returns
The number of participants including me, if it in.
Deprecated:
16/04/2021 Use linphone_conference_get_participant_count() instead.

◆ linphone_core_get_ldap_list()

bctbx_list_t* linphone_core_get_ldap_list ( LinphoneCore core)

Returns a list of entered LDAPs.

Items must be freed with linphone_ldap_unref()

Parameters
coreThe LinphoneCore object
Returns

◆ linphone_core_get_loaded_plugins()

const bctbx_list_t* linphone_core_get_loaded_plugins ( LinphoneCore core)

Return the list of loaded plugins.

Parameters
coreA LinphoneCore object
Returns
the list of loaded plugins

◆ linphone_core_get_push_notification_config()

const LinphonePushNotificationConfig* linphone_core_get_push_notification_config ( const LinphoneCore core)

Gets the push notification configuration object if it exists.

Parameters
coreThe LinphoneCore object
Returns
the LinphonePushNotificationConfig if it exists, NULL otherwise.

◆ linphone_core_is_plugin_loaded()

bool_t linphone_core_is_plugin_loaded ( const LinphoneCore core,
const char *  name 
)

Tells whether a plugin is loaded or not.

Parameters
coreA LinphoneCore object
namename of the plugin
Returns
A boolean value telling whether the plugin has been loaded

◆ linphone_core_remove_ldap()

void linphone_core_remove_ldap ( LinphoneCore core,
LinphoneLdap ldap 
)

Remove a LDAP from the configuration.

Parameters
coreLinphoneCore object
ldapThe LDAP to remove.

◆ linphone_core_set_chat_messages_aggregation_enabled()

void linphone_core_set_chat_messages_aggregation_enabled ( LinphoneCore core,
bool_t  enabled 
)

Sets whether chat messages grouping is enabled or not.

Set [sip] chat_messages_aggregation in your configuration file for the timer, default is 500ms.

Parameters
coreThe LinphoneCore object
enabledTRUE to wait for chat messages and notify them as at once, FALSE to keep legacy behavior.

◆ linphone_ldap_get_core()

LinphoneCore* linphone_ldap_get_core ( LinphoneLdap ldap)

Get the LinphoneCore object to which is associated the LinphoneLdap.

Parameters
ldapThe LinphoneLdap object.
Returns
The LinphoneCore object to which is associated the LinphoneLdap.

◆ linphone_ldap_get_index()

int linphone_ldap_get_index ( const LinphoneLdap ldap)

Get the index of the LinphoneLdap.

Parameters
ldapThe LinphoneLdap object.
Returns
The index of the Ldap

◆ linphone_ldap_get_params()

const LinphoneLdapParams* linphone_ldap_get_params ( LinphoneLdap ldap)

Get the LinphoneLdapParams as read-only object.

To make changes, clone the returned object using linphone_ldap_params_clone() method, make your changes on it and apply them using with linphone_ldap_set_params().

Parameters
ldapThe LinphoneLdap object.
Returns
The LinphoneLdapParams attached to this ldap.

◆ linphone_ldap_new()

LinphoneLdap* linphone_ldap_new ( LinphoneCore lc)

Create a new LinphoneLdap.

Call * linphone_ldap_set_params() to store the new LDAP configuration.

Parameters
lcThe LinphoneCore object.
Returns
The newly created LinphoneLdap object.

◆ linphone_ldap_new_with_params()

LinphoneLdap* linphone_ldap_new_with_params ( LinphoneCore lc,
LinphoneLdapParams params 
)

Create a new LinphoneLdap, associate it with the LinphoneLdapParams and store it into the configuration file.

Parameters
lcThe LinphoneCore object.
paramsThe LinphoneLdapParams object.
Returns
The newly created LinphoneLdap object.

◆ linphone_ldap_params_check()

int linphone_ldap_params_check ( const LinphoneLdapParams params)

Check parameters and return what are wrong.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The LinphoneLdapCheck values. LinphoneLdapCheckOk if everything is ok.

◆ linphone_ldap_params_clone()

LinphoneLdapParams* linphone_ldap_params_clone ( const LinphoneLdapParams params)

Instantiate a new LinphoneLdapParams with values from source.

Parameters
paramsThe LinphoneLdapParams object to be cloned.
Returns
The newly created LinphoneLdapParams object.

◆ linphone_ldap_params_enable_sal()

void linphone_ldap_params_enable_sal ( LinphoneLdapParams params,
bool_t  enable 
)

The dns resolution is done by Linphone using Sal.

It will pass an IP to LDAP. By doing that, the TLS negociation could not check the hostname. You may deactivate the verifications if wanted to force the connection. Default value : FALSE.

Parameters
paramsThe LinphoneLdapParams object.
enableEnable or not the use of sal.

◆ linphone_ldap_params_enable_tls()

void linphone_ldap_params_enable_tls ( LinphoneLdapParams params,
bool_t  enable 
)

Encrypt transactions by LDAP over TLS(StartTLS).

You must use 'ldap' scheme. 'ldaps' for LDAP over SSL is non-standardized and deprecated. StartTLS in an extension to the LDAP protocol which uses the TLS protocol to encrypt communication. It works by establishing a normal - i.e. unsecured - connection with the LDAP server before a handshake negotiation between the server and the web services is carried out. Here, the server sends its certificate to prove its identity before the secure connection is established. Default value : TRUE.

Parameters
paramsThe LinphoneLdapParams object.
enableEnable or not the use of TLS.

◆ linphone_ldap_params_get_auth_method()

LinphoneLdapAuthMethod linphone_ldap_params_get_auth_method ( const LinphoneLdapParams params)

Get the authentification method.

Check LinphoneLdapAuthMethod for authentification values.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The LinphoneLdapAuthMethod.

◆ linphone_ldap_params_get_base_object()

const char* linphone_ldap_params_get_base_object ( const LinphoneLdapParams params)

Get the BaseObject.

It is a specification for LDAP Search Scopes that specifies that the Search Request should only be performed against the entry specified as the search base DN. No entries above it will be considered. This field is required.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The specification.

◆ linphone_ldap_params_get_bind_dn()

const char* linphone_ldap_params_get_bind_dn ( const LinphoneLdapParams params)

Get the Bind DN to use for bindings.

The bindDN DN is the credential that is used to authenticate against an LDAP. If empty, the connection will be Anonymous. eg: cn=ausername,ou=people,dc=bc,dc=com

Parameters
paramsThe LinphoneLdapParams object.
Returns
The Bind DN to use for bindings.

◆ linphone_ldap_params_get_custom_value()

const char* linphone_ldap_params_get_custom_value ( const LinphoneLdapParams params,
const char *  key 
)

Get the value from field.

Parameters
paramsThe LinphoneLdapParams object.
keyThe key string.
Returns
The Value associated to the key.

◆ linphone_ldap_params_get_debug_level()

LinphoneLdapDebugLevel linphone_ldap_params_get_debug_level ( const LinphoneLdapParams params)

Return the debug verbosity level.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The LinphoneLdapDebugLevel debug level.

◆ linphone_ldap_params_get_delay()

int linphone_ldap_params_get_delay ( const LinphoneLdapParams params)

Get the delay between each search in milliseconds.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The delay in milliseconds.

◆ linphone_ldap_params_get_enabled()

bool_t linphone_ldap_params_get_enabled ( const LinphoneLdapParams params)

Return if the configuration is enabled.

Parameters
paramsThe LinphoneLdapParams object.
Returns
Enable or not the LDAP configuration.

◆ linphone_ldap_params_get_filter()

const char* linphone_ldap_params_get_filter ( const LinphoneLdapParams params)

Get the search is based on this filter to search contacts.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The filter to use.

◆ linphone_ldap_params_get_max_results()

int linphone_ldap_params_get_max_results ( const LinphoneLdapParams params)

Get the max results when requesting searches.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The max results when requesting searches.

◆ linphone_ldap_params_get_min_chars()

int linphone_ldap_params_get_min_chars ( const LinphoneLdapParams params)

Get the minimum characters needed for doing a search on LDAP servers.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The minimum characters needed by a search.

◆ linphone_ldap_params_get_name_attribute()

const char* linphone_ldap_params_get_name_attribute ( const LinphoneLdapParams params)

Get the attributes to build Name Friend, separated by a comma and the first is the highest priority.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The comma separated attributes for the search.

◆ linphone_ldap_params_get_password()

const char* linphone_ldap_params_get_password ( const LinphoneLdapParams params)

Get the password to pass to server when binding.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The password to pass to server when binding.

◆ linphone_ldap_params_get_server()

const char* linphone_ldap_params_get_server ( const LinphoneLdapParams params)

Get the LDAP Server.

Parameters
paramsThe LinphoneLdapParams object.
Returns
LDAP Server address.

◆ linphone_ldap_params_get_server_certificates_verification_mode()

LinphoneLdapCertVerificationMode linphone_ldap_params_get_server_certificates_verification_mode ( const LinphoneLdapParams params)

Return whether the tls server certificate must be verified when connecting to a LDAP server.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The TLS verification mode from LinphoneLdapCertVerificationMode

◆ linphone_ldap_params_get_sip_attribute()

const char* linphone_ldap_params_get_sip_attribute ( const LinphoneLdapParams params)

Get the attributes to build the SIP username in address of Friend.

Attributes are separated by a comma.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The comma separated attributes for building Friend.

◆ linphone_ldap_params_get_sip_domain()

const char* linphone_ldap_params_get_sip_domain ( const LinphoneLdapParams param)

Get the domain to the sip address(sip:username).

Parameters
paramsThe LinphoneLdapParams object.
Returns
The SIP domain for the friend.

◆ linphone_ldap_params_get_timeout()

int linphone_ldap_params_get_timeout ( const LinphoneLdapParams params)

Get the timeout for requests in seconds.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The timeout in seconds.

◆ linphone_ldap_params_get_timeout_tls_ms()

int linphone_ldap_params_get_timeout_tls_ms ( const LinphoneLdapParams params)

Get the timeout for TLS connection in milliseconds.

Parameters
paramsThe LinphoneLdapParams object.
Returns
The timeout in milliseconds.

◆ linphone_ldap_params_new()

LinphoneLdapParams* linphone_ldap_params_new ( LinphoneCore lc)

Create a new LinphoneLdapParams object.

Parameters
lcThe LinphoneCore object.
Returns
The newly created LinphoneLdapParams object.

◆ linphone_ldap_params_ref()

LinphoneLdapParams* linphone_ldap_params_ref ( LinphoneLdapParams params)

Take a reference on a LinphoneLdapParams.

Parameters
paramsThe LinphoneLdapParams object.
Returns
the same LinphoneLdapParams object.

◆ linphone_ldap_params_sal_enabled()

bool_t linphone_ldap_params_sal_enabled ( const LinphoneLdapParams params)

Return if the dns resolution is done by Linphone using Sal.

It will pass an IP to LDAP. By doing that, the TLS negociation could not check the hostname. You may deactivate the verifications if wanted to force the connection.

Parameters
paramsThe LinphoneLdapParams object.
Returns
Enable or not the use of sal.

◆ linphone_ldap_params_set_auth_method()

void linphone_ldap_params_set_auth_method ( LinphoneLdapParams params,
LinphoneLdapAuthMethod  auth_method 
)

Authentification method.

Check LinphoneLdapAuthMethod for authentification values. Default value : LinphoneLdapAuthMethodSimple

Parameters
paramsThe LinphoneLdapParams object.
auth_methodThe LinphoneLdapAuthMethod.

◆ linphone_ldap_params_set_base_object()

void linphone_ldap_params_set_base_object ( LinphoneLdapParams params,
const char *  base_object 
)

BaseObject is a specification for LDAP Search Scopes that specifies that the Search Request should only be performed against the entry specified as the search base DN.

No entries above it will be considered. This field is required. Default value : "dc=example,dc=com"

Parameters
paramsThe LinphoneLdapParams object.
base_objectThe specification.

◆ linphone_ldap_params_set_bind_dn()

void linphone_ldap_params_set_bind_dn ( LinphoneLdapParams params,
const char *  bind_dn 
)

Bind DN to use for bindings.

The bindDN DN is the credential that is used to authenticate against an LDAP. If empty, the connection will be Anonymous. eg: cn=ausername,ou=people,dc=bc,dc=com Default value : "".

Parameters
paramsThe LinphoneLdapParams object.
bind_dnThe Bind DN to use for bindings.

◆ linphone_ldap_params_set_custom_value()

void linphone_ldap_params_set_custom_value ( LinphoneLdapParams params,
const char *  key,
const char *  value 
)

Set custom field.

Parameters
paramsThe LinphoneLdapParams object.
keyThe key string.
valueThe value string.

◆ linphone_ldap_params_set_debug_level()

void linphone_ldap_params_set_debug_level ( LinphoneLdapParams params,
LinphoneLdapDebugLevel  level 
)

The debug verbosity level from internal LDAP API.

Values are LinphoneLdapDebugLevel Default value: LinphoneLdapDebugLevelOff

Parameters
paramsThe LinphoneLdapParams object.
levelThe LinphoneLdapDebugLevel debug level.

◆ linphone_ldap_params_set_delay()

void linphone_ldap_params_set_delay ( LinphoneLdapParams params,
int  delay 
)

Delay between each search in milliseconds Default value : 500.

Parameters
paramsThe LinphoneLdapParams object.
delayThe timeout in milliseconds.

◆ linphone_ldap_params_set_enabled()

void linphone_ldap_params_set_enabled ( LinphoneLdapParams params,
bool_t  enable 
)

If this config is enabled.

Default value : FALSE.

Parameters
paramsThe LinphoneLdapParams object.
enableEnable or not the LDAP configuration.

◆ linphone_ldap_params_set_filter()

void linphone_ldap_params_set_filter ( LinphoneLdapParams params,
const char *  filter 
)

The search is based on this filter to search contacts.

Default value : "(sn=*%s*)".

Parameters
paramsThe LinphoneLdapParams object.
filterThe filter to use.

◆ linphone_ldap_params_set_max_results()

void linphone_ldap_params_set_max_results ( LinphoneLdapParams params,
int  max_results 
)

The max results when requesting searches.

Default value : 5. This value fit for standard cases where only first results are needed. Also, it avoids latency on each searchs.

Parameters
paramsThe LinphoneLdapParams object.
max_resultsThe max results when requesting searches.

◆ linphone_ldap_params_set_min_chars()

void linphone_ldap_params_set_min_chars ( LinphoneLdapParams params,
int  min_chars 
)

The minimum characters needed for doing a search on LDAP servers.

Default value : 0.

Parameters
paramsThe LinphoneLdapParams object.
min_charsThe minimum characters needed by a search.

◆ linphone_ldap_params_set_name_attribute()

void linphone_ldap_params_set_name_attribute ( LinphoneLdapParams params,
const char *  name_attribute 
)

Check these attributes to build Name Friend, separated by a comma and the first is the highest priority.

Default value : "sn".

Parameters
paramsThe LinphoneLdapParams object.
name_attributeThe comma separated attributes for the search.

◆ linphone_ldap_params_set_password()

void linphone_ldap_params_set_password ( LinphoneLdapParams params,
const char *  password 
)

The password to pass to server when binding.

Default value : "".

Parameters
paramsThe LinphoneLdapParams object.
passwordThe password to pass to server when binding.

◆ linphone_ldap_params_set_server()

void linphone_ldap_params_set_server ( LinphoneLdapParams params,
const char *  server 
)

LDAP Server.

eg: ldap:/// for a localhost server or ldap://ldap.example.org/ Default value: "ldap:///". This field is required.

You must use 'ldap' scheme. 'ldaps' for LDAP over SSL is non-standardized and deprecated.

Parameters
paramsThe LinphoneLdapParams object.
serverLDAP Server address.

◆ linphone_ldap_params_set_server_certificates_verification_mode()

void linphone_ldap_params_set_server_certificates_verification_mode ( LinphoneLdapParams params,
LinphoneLdapCertVerificationMode  verify_server_certificates 
)

Specify whether the tls server certificate must be verified when connecting to a LDAP server.

Values are LinphoneLdapCertVerificationMode Default value : LinphoneLdapCertVerificationDefault (auto)

Parameters
paramsThe LinphoneLdapParams object.
verify_server_certificatesThe TLS verification mode from LinphoneLdapCertVerificationMode

◆ linphone_ldap_params_set_sip_attribute()

void linphone_ldap_params_set_sip_attribute ( LinphoneLdapParams params,
const char *  sip_attribute 
)

Check these attributes to build the SIP username in address of Friend.

Attributes are separated by a comma. Default value : "mobile,telephoneNumber,homePhone,sn".

Parameters
paramsThe LinphoneLdapParams object.
sip_attributeThe comma separated attributes for building Friend.

◆ linphone_ldap_params_set_sip_domain()

void linphone_ldap_params_set_sip_domain ( LinphoneLdapParams params,
const char *  sip_domain 
)

Add the domain to the sip address(sip:username).

By default or if it is empty, the domain will be specify while searching on the current proxy account. Default value : "".

Parameters
paramsThe LinphoneLdapParams object.
sip_domainThe SIP domain for the friend.

◆ linphone_ldap_params_set_timeout()

void linphone_ldap_params_set_timeout ( LinphoneLdapParams params,
int  timeout 
)

Timeout for requests in seconds.

It limits the time for searchs and the value is passed to Ldap with LDAP_OPT_NETWORK_TIMEOUT. Default value : 5.

Parameters
paramsThe LinphoneLdapParams object.
timeoutThe timeout in seconds.

◆ linphone_ldap_params_set_timeout_tls_ms()

void linphone_ldap_params_set_timeout_tls_ms ( LinphoneLdapParams params,
int  timeout 
)

Timeout for TLS connection in milliseconds.

Default value : 1000.

Parameters
paramsThe LinphoneLdapParams object.
timeoutThe timeout in milliseconds.

◆ linphone_ldap_params_tls_enabled()

bool_t linphone_ldap_params_tls_enabled ( const LinphoneLdapParams params)

Return if transactions are encrypted by LDAP over TLS(StartTLS).

You must use \'ldap\' scheme. \'ldaps\' for LDAP over SSL is non-standardized and deprecated. StartTLS in an extension to the LDAP protocol which uses the TLS protocol to encrypt communication. It works by establishing a normal - i.e. unsecured - connection with the LDAP server before a handshake negotiation between the server and the web services is carried out. Here, the server sends its certificate to prove its identity before the secure connection is established.

Parameters
paramsThe LinphoneLdapParams object.
Returns
Enable or not the use of TLS.

◆ linphone_ldap_params_unref()

void linphone_ldap_params_unref ( LinphoneLdapParams params)

Release a LinphoneLdapParams.

Parameters
paramsThe LinphoneLdapParams object.

◆ linphone_ldap_ref()

LinphoneLdap* linphone_ldap_ref ( LinphoneLdap ldap)

Take a reference on a LinphoneLdap.

Parameters
ldapThe LinphoneLdap object.
Returns
the same LinphoneLdap object.

◆ linphone_ldap_set_index()

void linphone_ldap_set_index ( LinphoneLdap ldap,
int  index 
)

Set the index associated to the LinphoneLdap.

Parameters
ldapThe LinphoneLdap object.
Theindex of the Ldap. Can be -1 : it will be determined on save.

◆ linphone_ldap_set_params()

void linphone_ldap_set_params ( LinphoneLdap ldap,
LinphoneLdapParams params 
)

Set the LinphoneLdapParams used by this LinphoneLdap.

The parameters will be saved in the configuration file.

Parameters
ldapThe LinphoneLdap object.
paramsThe LinphoneLdapParams object.

◆ linphone_ldap_unref()

void linphone_ldap_unref ( LinphoneLdap ldap)

Release a LinphoneLdap.

Parameters
ldapThe LinphoneLdap object.