32-bit Client ldapsearch Fails With *** Glibc Detected *** Ldapsearch: Double Free Or Corruption (!prev): (Doc ID 2277019.1)

Last updated on JULY 23, 2017

Applies to:

Oracle Internet Directory - Version 11.1.0.6 and later
Information in this document applies to any platform.

Symptoms

The ldapsearch utility delivered as part of an Oracle DB client 32 bit 11gR2 installation on Linux fails with certain filters:

$ echo $LD_LIBRARY_PATH
/opt/brm/ThirdParty/ctq/lib:/opt/brm/ThirdParty/ctq/bin/odbc:/opt/brm/ThirdParty/ctq/bin/odbc/lib:/opt/brm/7.4/pin441/rel/lib:/opt/oracle/apps/product/11.2.0/client_32/lib32:/opt/oracle/apps/product/11.2.0/client_32/lib:/usr/local/lib/hpux32

$ ldapsearch -h oracle.ad -p 389 -D ora_SVNBRM -w welcome1-b "dc=sjrb,dc=ad" "&(memberOf=CN=ora.dev,OU=Role Based,OU=Security,OU=Groups,OU=Dev,DC=oracle,DC=AD)(givenName=t*)"


*** glibc detected *** ldapsearch: double free or corruption (!prev): 0x080da660 ***
======= Backtrace: =========
/lib/libc.so.6(+0x691c91)[0x5460c91]
/lib/libc.so.6(+0x6946f1)[0x54636f1]
ldapsearch(gslumfFree+0x44)[0x80a354c]
ldapsearch(gslcseb_BuildSearchReq+0xca)[0x8075c5c]
ldapsearch(gslcsex_LdapSearchExt+0xeb)[0x8075e49]
ldapsearch(ora_ldap_search_ext+0x78)[0x805f356]
ldapsearch(ldap_search_ext+0x50)[0x8062536]
ldapsearch[0x805d10a]
ldapsearch[0x805b1b1]
/lib/libc.so.6(__libc_start_main+0xe6)[0x5406d26]
ldapsearch[0x8055131]
======= Memory map: ========
001a5000-003c8000 r-xp 00000000 fd:05 2997777                            /opt/oracle/apps/product/11.2.0/client_32/lib/libnnz11.so
003c8000-003f7000 rw-p 00222000 fd:05 2997777                            /opt/oracle/apps/product/11.2.0/client_32/lib/libnnz11.so
003f7000-003f8000 rw-p 00000000 00:00 0
003f8000-003fb000 r-xp 00000000 fd:00 266001                             /lib/libdl-2.12.so
003fb000-003fc000 r--p 00002000 fd:00 266001                             /lib/libdl-2.12.so
003fc000-003fd000 rw-p 00003000 fd:00 266001                             /lib/libdl-2.12.so
003fd000-00425000 r-xp 00000000 fd:00 266009                             /lib/libm-2.12.so
00425000-00426000 r--p 00027000 fd:00 266009                          

If setting the malloc variable as per:  Bulkload Fails With Error "*** Glibc Detected *** Bulkload: Corrupted Double-linked List" (Doc ID 2229466.1) then the search returns data but still errors with:

$ ldapsearch -h oracle.ad -p 389 -D ora_SVNBRM -w welcome1-b "dc=sjrb,dc=ad" "&(memberOf=CN=ora.dev,OU=Role Based,OU=Security,OU=Groups,OU=Dev,DC=oracle,DC=AD)(givenName=t*)"


*** glibc detected *** ldapsearch: free(): invalid pointer: 0x080daa70 *** <<<<<<
CN=tttester11,OU=Processes,OU=Privileged Accounts,OU=Accounts,OU=Corp,DC=ORACLE,DC=AD
objectClass=top
objectClass=person
objectClass=organizationalPerson
objectClass=user
cn=tttester11
......

The search works if an additional letter is added to the last filter, ie givenname=tt* instead of just givenname=t*, eg:

Works:
$ ldapsearch -h oracle.ad -p 389 -D ora_SVNBRM -w welcome1-b "dc=sjrb,dc=ad" "&(memberOf=CN=ora.dev,OU=Role Based,OU=Security,OU=Groups,OU=Dev,DC=oracle,DC=AD)(givenName=tt*)"

Fails:
$ ldapsearch -h oracle.ad -p 389 -D ora_SVNBRM -w welcome1-b "dc=sjrb,dc=ad" "&(memberOf=CN=ora.dev,OU=Role Based,OU=Security,OU=Groups,OU=Dev,DC=oracle,DC=AD)(givenName=t*)"


Relinking the 32bit client was tried as follows, but it did not help:
cd /opt/oracle/apps/product/11.2.0/client_32/bin - DONE
relink all

RPMs already checked as per: Requirements for Installing Oracle 11gR2 RDBMS on RHEL6 or OL6 64-bit (x86-64) (Doc ID 1441282.1)

Installing 11.2.0.4 32-bit client from: https://updates.oracle.com/download/13390677.html (file p13390677_112040__4of7.zip) did not help either.

 

NOTE: This behavior was detected with the filter and conditions described above but it is not known if the issue can also be reproduced under different circumstances.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms