Full_Name: Dmitry Bakshaev Version: 2.4.38, 2.4.40 OS: gentoo linux URL: ftp://ftp.openldap.org/incoming/ Submission from: (NULL) (87.249.250.7)
slapd.conf: include /etc/openldap/schema/core.schema pidfile /tmp/openldap-data-test/slapd.pid argsfile /tmp/openldap-data-test/slapd.args database mdb directory /tmp/openldap-data-test suffix "c=ru" index objectClass eq
test.ldif: dn: c=ru objectClass: country c: ru
dn: o=org,c=ru objectClass: organization o: org
dn: ou=unit,o=org,c=ru objectClass: organizationalUnit ou: unit
dn: ou=subunit,ou=unit,o=org,c=ru objectClass: organizationalUnit ou: subunit
dn: cn=pers,ou=unit,o=org,c=ru objectClass: person cn: pers sn: pers
load test.ldif: slapadd -f slapd.conf -l test.ldif -q
run slapd: /usr/lib/openldap/slapd -f slapd.conf -d 127 -h "ldap:///"
execute query: ldapsearch -H ldaps://localhost -b ou%ununit,o=org,c=ru -s one "(objectclass=organizationalUnit)"
result contains wrong data (expects only ou=subunit,ou=unit,o=org,c=ru): # unit, org, ru dn: ou=unit,o=org,c=ru objectClass: organizationalUnit ou: unit
# subunit, unit, org, ru dn: ou=subunit,ou=unit,o=org,c=ru objectClass: organizationalUnit ou: subunit
# search result search: 2 result: 0 Success
# numResponses: 3 # numEntries: 2
worked as expected: 1. on openldap-2.4.35 (with mdb 0.9.6) or below; or 2. with "database bdb"; or 3. without "index objectClass eq".