python-ldap, compare_s() return only true in all cases

Fernando Ribeiro fernando at gentoo-br.org
Sun Apr 30 13:55:41 CEST 2006


Hi Michael,

Michael Ströder wrote:
> Fernando Ribeiro wrote:
>   
>>    I'm studing the python, and begin with python-ldap. But i have a
>> little problem with ldap.compare_s(dn, attr, value) function.
>>     
>
> Please subscribe and post to python-ldap-dev list (Cc:-ed).
>
> https://lists.sourceforge.net/lists/listinfo/python-ldap-dev
>
>   
subscribed, thanks.
>>    While using ldap_slave.compare_s("dc=domain,dc=com,dc=br",
>> "objectClass", "top");
>>    It return true.
>>    But look in ldap_slave don't have the 'objectClass: top'.
>>     
>
> Every structural object class is implicitly derived from 'top'. So I'd
> expect this to evaluate to True each time.
>   
It return true to all objectClasses.
With others atribute (except objectClass) it work fine.
I have tested with C too, and it return the same result.
Its "ignoring" the objectClass to compare.

> What exactly are you trying to achieve?
>
> Could you please verify with another attribute?
>
> Ciao, Michael.
>
>   
    Exists other way to compare entries?

    Thank you a million by attention.


Best Regards,
Fernando Ribeiro

-- 
--------------------------------------------------
- Fernando Ribeiro - GPG-KEY: 0x8D7255F4
- Linux Counter: #273768 - ICQ: 175630330
- RHCE - Red Hat Certified Engineer
- LPIC-2 - Advanced Linux
- CCSA - CheckPoint Cert. Security Admin.
- phone: +55 61 9115 4852
- http://www.musb.org
--------------------------------------------------
Firthunands (firthu quer dizer "paz", nands
significa audaz. Dessa maneira, a tradução seria:
"Aquele que se atreve a tudo para conservar a Paz"



More information about the python-ldap mailing list