LDAP structure (winldap.h)

The LDAP structure represents an LDAP session. Typically, a session corresponds to a connection to a single server. However, in the case of referrals, an LDAP session may encompass several server connections. The ability to track referrals is available in LDAP 3.

Syntax

typedef struct ldap {
  struct {
    UINT_PTR  sb_sd;
    UCHAR     *Reserved1[(10  sizeof(ULONG))+ 1];
    ULONG_PTR sb_naddr;
    UCHAR     *Reserved2[(6  sizeof(ULONG))];
  } ld_sb;
  PCHAR  ld_host;
  ULONG  ld_version;
  UCHAR  ld_lberoptions;
  ULONG  ld_deref;
  ULONG  ld_timelimit;
  ULONG  ld_sizelimit;
  ULONG  ld_errno;
  PCHAR  ld_matched;
  PCHAR  ld_error;
  ULONG  ld_msgid;
  UCHAR  *Reserved3[(6  sizeof(ULONG))+ 1];
  ULONG  ld_cldaptries;
  ULONG  ld_cldaptimeout;
  ULONG  ld_refhoplimit;
  ULONG  ld_options;
} LDAP, *PLDAP;

Members

ld_sb

ld_sb.sb_sd

ld_sb.Reserved1[(10 * sizeof(ULONG))+ 1]

ld_sb.sb_naddr

ld_sb.Reserved2[(6 * sizeof(ULONG))]

ld_host

ld_version

ld_lberoptions

ld_deref

ld_timelimit

ld_sizelimit

ld_errno

ld_matched

ld_error

ld_msgid

Reserved3[(6 * sizeof(ULONG))+ 1]

ld_cldaptries

ld_cldaptimeout

ld_refhoplimit

ld_options

Remarks

An LDAP structure is an opaque data type allocated and initialized by a call to ldap_init, cldap_open, or ldap_open. Subsequent LDAP calls pass a handle to this structure, which maintains the state of an LDAP session for the duration of the connection. When the session ends, call ldap_unbind to destroy the connection handle.

Although this is an opaque data type, it is documented in Winldap.h. This is primarily of value in porting applications written using other LDAP client implementations. Call ldap_get_option or ldap_set_option to access or change the values associated with the LDAP connection handle (this structure). Using these two functions also expose settings not directly accessible from the LDAP structure. For more information about session options, see Session Options.

Requirements

Requirement Value
Minimum supported client Windows Vista
Minimum supported server Windows Server 2008
Header winldap.h

See also

Data Structures

cldap_open

ldap_get_option

ldap_init

ldap_open

ldap_set_option

ldap_unbind