14.3. LDAPControl
Table 14.2. Frontend API Functions for LDAP Controls
| To perform this action... | Call this function |
|---|---|
| Append a control to the end of an array or to a new array. | slapi_add_control_ext() |
| Append an array of controls to the end of an array or to a new array. | slapi_add_controls() |
|
Create an LDAPControl structure based on a BerElement, an OID, and a criticality flag. It returns an LDAP error code.
| slapi_build_control() |
|
Create an LDAPControl structure based on a struct berval, an OID, and a criticality flag. It returns an LDAP error code.
| slapi_build_control_from_berval() |
|
Check for the presence of a specific LDAPControl. It returns non-zero for presence and zero for absence.
| slapi_control_present() |
Retrieve the LDAPMod contained in a Slapi_Mod structure. | slapi_mod_get_ldapmod_passout() |
| Register the specified control with the server. This function associates the control with an object identification (OID). | slapi_register_supported_control() |
| Retrieve an allocated array of object identifiers (OIDs) representing the controls supported by the Directory Server. | slapi_get_supported_controls_copy() |
This struct definition uses the following syntax:
typedef struct ldapcontrol {
char *ldctl_oid;
struct berval ldctl_value;
char ldctl_iscritical;
} LDAPControl;
This function has the following parameters:
Table 14.3. LDAPControl Parameters
| Field | Description |
|---|---|
ldctl_oid | Object ID (OID) of the control. |
ldctl_value | berval structure containing the value used by the control for the operation. |
ldctl_iscritical | Specifies whether the control is critical to the operation. This field can have one of the following values:
|

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.