https://bugzilla.redhat.com/show_bug.cgi?id=513019
Summary: nsslapd-lookthroughlimit is not respected when the
filter test failed in search
Product: 389
Version: 1.2.0
Platform: All
OS/Version: Linux
Status: NEW
Severity: medium
Priority: low
Component: Database - Indexes/Searches
AssignedTo: nhosoi(a)redhat.com
ReportedBy: nhosoi(a)redhat.com
QAContact: ckannan(a)redhat.com
CC: sramling(a)redhat.com
Blocks: 434915
Estimated Hours: 0.0
Classification: Other
Target Release: ---
Description of problem:
Bug report by Sankar Ramalingam:
Test Setup 1:
Simple paged with sorting with all default configuration values except
nsslapd-lookthroughlimit is set to 100
Added 400 users to the suffix.
Simple paged search request with normal user.
perl ./data/ldap_usr_search.pl -x -pg 90 "cn=test*" -S "cn"
"dn"
Problem sorting, LDAP_ADMIN_LIMIT_EXCEEDED
next page size (90):
Result; This returns 90 entries and the ADMIN_LIMIT_EXCEEDED error.
perl ./data/ldap_usr_search.pl -x -pg 91 "cn=test*" -S "cn"
"dn"
search failed: LDAP_ADMIN_LIMIT_EXCEEDED
Result: Search fails. Though the limit is set to 100, it fails for 91st entry.
[Proposed Fix]
Created an attachment (id=354532)
--> (
https://bugzilla.redhat.com/attachment.cgi?id=354532)
git patch file for ldbm_search.c
File: ldap/servers/slapd/back-ldbm/ldbm_search.c
Fix Description: When filter test is necessary against the search results
and the test fails, lookthroughcount attached to the search result structure
should have been decremented since the entry will not be sent to the client,
but it was not. This change fixes it.