Hi,

On Friday 22 April 2005 17:35, Gautam Gopalakrishnan wrote:
> Some attributes don't change values very often and sometime you don't
> need the latest information? Maybe it's just me, but I thought this
> would be useful. I've started coding it, just for the challenge.

You may use ldifgrep (http://sourceforge.net/projects/ldifgrep).
It's a perl script that greps the entries from an LDIF file where
the arguments matches an attribute's value

The problem for applying filters on LDIF entries is that you do not
know about the syntaxes of the attributes and thus do not know
how to compare the values.

An extreme example is certificateMatch as it is implemented in OpenLDAP 2.2:
A filter like 
  ([EMAIL PROTECTED],CN=John Doe,O=Example\5C,Ltd.,C=US)
finds objects that have the userCertificate attribute filled with a X.509 
certificate with serial number 2 and the subject DN (in the X.509 notation)
  /C=US/O=Example\5C,Ltd./CN=John Doe/[EMAIL PROTECTED]

Trying to do things like that on LDIF files is quite hard IMHO (and one of the 
major steps towards an LDAP server in Perl ;-)

Have fun
Peter
-- 
Peter Marschall
eMail: [EMAIL PROTECTED]

Reply via email to