Home > Archive > LDAP > July 2006 > compare a NULL value with unexpected result code
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
compare a NULL value with unexpected result code
|
|
| Cai Qian 2006-07-07, 4:03 am |
| Hi,
For Perl-LDAP 0.33, I try to $ldap->compare ($entry=>dn,
attr=>'attribute', value=''), and it give me OPERATION_ERROR. However,
if I use OpenLDAP's ldapcompare with "attribute:", it give me
LDAP_COMPARE_TRUE. It seems to me Perl-LDAP sends an incorrect message
to LDPA server.
Qian
| |
| Chris Ridd 2006-07-08, 7:02 pm |
| On 7/7/06 6:07, Cai Qian <caiqian@gmail.com> wrote:
> Hi,
>
> For Perl-LDAP 0.33, I try to $ldap->compare ($entry=>dn,
> attr=>'attribute', value=''), and it give me OPERATION_ERROR. However,
> if I use OpenLDAP's ldapcompare with "attribute:", it give me
> LDAP_COMPARE_TRUE. It seems to me Perl-LDAP sends an incorrect message
> to LDPA server.
It is working for me here, as is ldapcompare. In fact turning up debug in
Net::LDAP and ldapcompare reveals the exact same bytes are sent for the
compare operation so you'd expect it to work the same.
Can you do the same ($ld->debug(15) with Net::LDAP and pass -d 255 to
ldapcompare) and see if you can spot any differences?
Cheers,
Chris
| |
| Peter Marschall 2006-07-08, 7:02 pm |
| Hi,
On Friday, 7. July 2006 07:07, Cai Qian wrote:
> For Perl-LDAP 0.33, I try to $ldap->compare ($entry=>dn,
> attr=>'attribute', value=''), and it give me OPERATION_ERROR. However,
> if I use OpenLDAP's ldapcompare with "attribute:", it give me
> LDAP_COMPARE_TRUE. It seems to me Perl-LDAP sends an incorrect message
> to LDPA server.
What does it say when $ldap->debug(15) is called before the compare() call ?
Peter
--
Peter Marschall
peter@adpm.de
| |
| Cai Qian 2006-07-10, 7:03 pm |
| Hi,
On 7/8/06, Chris Ridd <chrisridd@mac.com> wrote:
> On 7/7/06 6:07, Cai Qian <caiqian@gmail.com> wrote:
>
>
> It is working for me here, as is ldapcompare. In fact turning up debug in
> Net::LDAP and ldapcompare reveals the exact same bytes are sent for the
> compare operation so you'd expect it to work the same.
>
> Can you do the same ($ld->debug(15) with Net::LDAP and pass -d 255 to
> ldapcompare) and see if you can spot any differences?
>
> Cheers,
>
> Chris
>
In fact, it is a bug in the testing server, which is unable to handle
comparing with NULL value with a control parameter (even empty).
Thanks for the help.
Qian
|
|
|
|
|