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

Re: openldap search filter attribut equal to another

Peter Gietz wrote:
Am 05.03.2014 09:52, schrieb Lanfeust troy:
hi list,

is it possible to write a filter like:


to retrieve all entry that attribute mail equal to attribute cn.

No, RFC 4515 does not define such. On the right side of the operator
("filtertype") an attribute value ("assertionvalue") is expected and not
an attribute type ("attr" which is "attributedescription"). "attr" is
only is expected on the left side of the operator:
simple         = attr filtertype assertionvalue

You will need a little scripting to achieve what you want.

Or propose an extended matching rule, write a spec for it, and get some code written to implement it. For this particular use case it probably wouldn't be too hard.



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