[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: (ITS#5614) Ignore invalid search filters

ando@sys-net.it wrote:
> andrew.graham@agustawestland.com wrote:
>> In line with the behavious specified in ITS 3785, any invalid search filter
>> applied against back-meta will force a query including the search filter
>> (!(objectClass=*)). As this filter can result in slow performance for certain
>> brands of LDAP server, please provide an option to ignore invalid search filters
>> in back-meta.
> A patch is in HEAD for back-ldap&  back-meta.  Use the "noundeffilter
> {true|FALSE}" statement.  Please test.  p.

I don't think ldap_munge_filter() is adequate any more. Note that filter2bv 
doesn't use (?=undefined) for unknown attributeTypes or illegal values any 
more, it uses (?<attr>=<value>). This change was made to allow the log 
messages to show what the actual offending values were. A better strategy here 
may be to walk the Filter tree and look for 
(f->f_choice&SLAPD_FILTER_UNDEFINED) before making the search request, so that 
no retries are needed.

   -- Howard Chu
   CTO, Symas Corp.           http://www.symas.com
   Director, Highland Sun     http://highlandsun.com/hyc/
   Chief Architect, OpenLDAP  http://www.openldap.org/project/