ldap_add_control()--Create a Control and Insert it into the List of LDAP Server Controls
Syntax
#include <ldap.h> int ldap_add_control( char *oid, ber_len_t len, char *value, int isCritical, LDAPControl ***ctrlList)
Library Name/Service Program: QSYS/QGLDCLNT
Default Public Authority: *USE
Threadsafe: Yes
The ldap_add_control() function is used to create a control and insert it into the list of LDAP server controls.
Note: The function will allocate space in the list for the control.
Authorities and Locks
No IBM® i authority is required. All authority checking is done by the LDAP server.
Parameters
- oid
- (Input) Specifies the control type, represented as a string.
- len
- (Input) Specifies the length of the value string.
- value
- (Input) Specifies the data associated with the control.
- isCritical
- (Input) Specifies whether the control is critical or not.
- ctrlList
- (Input) Specifies a list of LDAP server controls. See Controls for LDAP APIs for more information about server controls.
Return Value
- LDAP_SUCCESS
- if the request was successful.
- LDAP_NO_MEMORY
- if the control could not be added.
Related Information
- ldap_insert_control() -- Insert a control in the list of LDAP server controls.
- ldap_remove_control() -- Remove a control from the list of LDAP server controls.
- ldap_copy_controls() -- Synchronously add an entry with controls.
API introduced: V5R3
[ Back to top | LDAP APIs | APIs by category ]