ldap_set_option (Windows CE 5.0)

Send Feedback

This function sets options on connection blocks.

ULONG ldap_set_option(LDAP* ld,intoption,void* invalue);

Parameters

  • ld
    [in] Session handle.
  • option
    [in] Name of the session option being set. For more information, see Session Options.
  • invalue
    [in] Pointer to the value that the option is to be given. The actual type of this parameter depends on the setting of the option parameter. The constants LDAP_OPT_ON and LDAP_OPT_OFF can be given for options that have on or off settings.

Return Values

If this function succeeds, the return value is LDAP_SUCCESS.

If this function fails, it returns an error code. See the LDAP_RETCODE enumeration for a list of possible return values.

Remarks

Call this function to access the LDAP structure that represents an LDAP session. Do not attempt to modify the LDAP data structure directly.

To enable signing/sealing, you have to turn on one of the following options prior to calling ldap_bind_s.

#define LDAP_OPT_SIGN      0x95
#define LDAP_OPT_ENCRYPT   0x96

To turn off signing/sealing, you have to close the connection by calling the ldap_unbind function on the connection handle.

In a multithreading environment, calls to ldap_set_option are not thread-safe because it affects the connection as a whole.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Winldap.h.
Link Library: Wldap32.lib.

See Also

LDAP_RETCODE | LDAP | ldap_bind_s | ldap_get_option | ldap_unbind

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.