Network Working Group T. Howes
Request for Comments: 1558 University of Michigan
Category: Informational December 1993
A String Representation of LDAP Search Filters
1. LDAP Search Filter Definition
An LDAP search filter is defined in [1] as follows:
any [1] LDAPString,
final [2] LDAPString
}
} AttributeValueAssertion ::= SEQUENCE attributeType AttributeType, attributeValue AttributeValue }
Howes [Page 1]
RFC 1558 Representation of LDAP Filters December 1993
AttributeType ::= LDAPString
2. String Search Filter Definition
The string representation of an LDAP search filter is defined by the following BNF. It uses a prefix format.
<filter> ::= '(' <filtercomp> ')'
<filtercomp> ::= <and> | <or> | <not> | <item>
<and> ::= '&' <filterlist>
<or> ::= '|' <filterlist> <not> ::= '!' <filter>
<filterlist> ::= <filter> | <filter> <filterlist>
<item> ::= <simple> | <present> | <substring>
<simple> ::= <attr> <filtertype> <value>
<filtertype> ::= <equal> | <approx> | <greater> | <less>
<equal> ::= '='
<approx> ::= '~=' <greater> ::= '>=' <less> ::= '<=' <present> ::= <attr> '=*' <substring> ::= <attr> '=' <initial> <any> <final> <initial> ::= NULL | <value> <any> ::= '*' <starval> <starval> ::= NULL | <value> '*' <starval> <final> ::= NULL | <value>
Howes [Page 2]
RFC 1558 Representation of LDAP Filters December 1993 3. ExamplesThis section gives a few examples of search filters written using this notation.
4. Security Considerations
Security issues are not discussed in this memo.
5. References
[1] Yeong, W., Howes, T., and S. Kille, "Lightweight Directory Access
6. Author's Address
Tim Howes University of Michigan ITD Research Systems 535 W William St. Ann Arbor, MI 48103-4943 USA