[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: ldapcompare tool (ITS#1560)
At 01:57 PM 2002-01-28, j.costlow@f5.com wrote:
>Full_Name: Jeff Costlow
>Version: HEAD
>OS: Linux, freeBSD
>URL: ftp://ftp.openldap.org/incoming/
>Submission from: (NULL) (205.229.151.150)
The URL for this contribution is:
ftp://ftp.openldap.org/incoming/ldapcompare.tar.gz
A few comments:
>An ldapcompare implementation, including a man page. Built against 2.0.21, but
>should apply cleanly to HEAD.
>
>To apply copy the tar file into your topdir, and untar it. 3 files are
>contained
>ldapcompare.patch
>clients/tools/ldapcompare.c
>doc/man/man1/ldapcompare.1
>
>Apply the patch:
>patch -p0 <ldapcompare.patch.
>
>The patch file only patches clients/tools/Makefile.in to know about the new
>ldapcompare.c. The new man page will be noticed at maketime.
>
>Notes:
>I basically just beat up ldapsearch, so i left in some options, like
>dereferencing and timelimits, that may not mean anything.
Starting from ldapdelete would likely have been better, it
doesn't have all the search specific options. So, no cruft
to clean up.
Anyways, please do remove all the search specific options.
>The good side is that
>all the options are the same.
>I wanted a mode for shell scripts, so there is a new option -q that will never
>write anything out, but will return 5 for LDAP_COMPARE_FALSE, 6 for
>LDAP_COMPARE_TRUE. If you don't use -q, then both LDAP_COMPARE_FALSE and
>LDAP_COMPARE_TRUE will return 0. This keeps with the tradition of returning 0
>on success.
-q is reserved for later use (across all ldap*(1) tools).
-z would be a better choice.
>Support for comparing binary attributes would probably require an option for
>file support and would pass in a ber_value to do_compare instead of a char*.
I suggest supporting base64 encoded assertion values.
I'd suggest using an LDIFv1 like syntax:
foo:bar
data::b64dada
extra credit for URL support.
And bonus points for a testXXX-compare test.
Kurt