ldap_create_geteffective_control

Creates and encodes a get effective privilege control.

LDAP Version:v3
Library:*ldapsdk.*
NDS Version:8.xx or higher
Platform:NLM, Windows (NT, 95, 98, 2000, XP, Vista 32-bit and 64-bit ), Linux (32-bit and 64-bit), Solaris, AIX, and HP-UX

Syntax

  #include <ldap.h>ldap_create_geteffective_control  (
    LDAP                     *ld,                 
    LDAPGetprvInfo               **getprvinfo,
    int             efPrvvalue,                 
    int         isCritical,                 
    LDAPControl   **ctrlp ));
  

Parameter

ld

(IN) Points to the handle for the LDAP session obtained from a call to ldap_init().

Getprvinfo

(IN) Points to a null-terminated array of pointers to LDAPGetprvInfo structures, containing a description of each of the EffectivePrivilege value selection type.

efPrvvalue

(IN) Specifies a bool value indicating includeAllLegalAttributes value is seclected. -1 indicates that the includeAllLegalAttributes value is not selected.

isCritical

(IN) Indicates the criticality of the control to the operation. 0 indicates that the control is not critical to the operation and a non-zero values indicates that the control is critical to the operation.

ctrlp

(OUT) Returns a pointer to the created LDAPControl. This control is free from calling the ldap_control_free() after returning the pointer.

Return Values

0x00

LDAP_SUCCESS

Non-zero

Failure. See LDAP Return Codes

Remarks

The ldap_create_geteffective_control creates a sort control, that can be used as the server control parameter in the ldap_search_ext and the ldap_search_ext_s functions.