Note that there are some explanatory texts on larger screens.

plurals
  1. POldap_search_sW function crashing on Windows Server 2012 R2 X64?
    primarykey
    data
    text
    <p>For searching for a particular user in Active Directory Services, we have used <code>ldap_search_sW</code> API. It is however , crashing my exe in case of Windows Server 2012. No error code is returned , the EXE just stops working.</p> <p>THe EXE i have is 32 bit application. So i guess it will load from "SysWow64" directory. Here is a sample line as to how the calling is done :-</p> <p>Declaration of pld :</p> <pre><code>type // record declaration begins {$EXTERNALSYM PLDAP} PLDAP = ^LDAP; {$EXTERNALSYM LDAP} LDAP = record ld_sb: record sb_sd: ULONG; Reserved1: array [0..(10 * sizeof(ULONG))] of Byte; sb_naddr: ULONG; // notzero implies CLDAP available Reserved2: array [0..(6 * sizeof(ULONG)) - 1] of Byte; // // Following parameters MAY match up to reference implementation of LDAP // ld_host: PChar; ld_version: ULONG; ld_lberoptions: Byte; // // Safe to assume that these parameters are in same location as // reference implementation of LDAP API. // ld_deref: ULONG; ld_timelimit: ULONG; ld_sizelimit: ULONG; ld_errno: ULONG; ld_matched: PChar; ld_error: PChar; ld_msgid: ULONG; Reserved3: array [0..(6*sizeof(ULONG))] of Byte; // // Following parameters may match up to reference implementation of LDAP API. // ld_cldaptries: ULONG; ld_cldaptimeout: ULONG; ld_refhoplimit: ULONG; ld_options: ULONG; end; // record declaration end pld : PLDAP; pld := Session.pld; // session PLD is assigned as is to it The sessions' PLD is initialized as ldappld := ldap_initW(PWideChar(ldapServerW), ldapPort) // this is eventually assigned to Session's PLD which is assigned to the PLD used Below LdapCheck(ldap_search_sW(pld, PWideChar('DC=esbs,DC=local'), LDAP_SCOPE_SUBTREE, '(objectCategory=user)', nil, 0, plmSearch)); </code></pre> <p>WHat steps should i take ?</p> <p>Here is the windows dump of the EXE crash :</p> <pre><code> Problem signature: Problem Event Name: APPCRASH Application Name: project1.exe Application Version: 0.1.1.0 Application Timestamp: 2a425e19 Fault Module Name: KERNELBASE.dll Fault Module Version: 6.2.8400.0 Fault Module Timestamp: 4fb7184e Exception Code: 000006ba Exception Offset: 00017945 OS Version: 6.2.8400.2.0.0.400.8 Locale ID: 1033 Additional Information 1: 91d0 Additional Information 2: 91d025961d4c758a8b5ea7ee1390f3b7 Additional Information 3: c3ce Additional Information 4: c3cebe78f080ab69603c33ad36d75750 </code></pre> <p>Declaration of function:</p> <pre><code> {$EXTERNALSYM ldap_search_sW} function ldap_search_sW(ld: PLDAP; base: PWideChar; scope: ULONG; filter, attrs: PWideChar; attrsonly: ULONG; var res: PLDAPMessage): ULONG; cdecl; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload