Implementation of LDAPControls

Michael Ströder michael at stroeder.com
Fri Feb 25 18:29:36 CET 2005


Deepak Giridharagopal wrote:
> 
> I've attached a unified diff of my changes, which as I said before are
> modeled closely after the existing implementation of LDAPMod structures.

I've committed your patches to CVS since they seem to be the most 
complete solution. But I'd really prefer to have code without 
goto-statements. Could you please work out a solution for this? And 
maybe it would be nice to extract the helper functions for LDAPControls 
to a separate C source text called ldapcontrols.c?

One thing I wonder about is whether it's possible to send a control 
where the control value is absent (e.g. by passing None as control 
value)? See RFC3296 chapter 3 for an example (ManageDsaIT Control).

Now for the Python parts:

I fixed some wrong argument lists in ldap.ldapobject.LDAPObject to make 
it work correctly at that level.
(Note that importing _ldap is considered bad!)

I also started to work on a basic Python class API in sub-module 
ldap.controls. I could not test it yet. But you get the idea.

Regarding ManageDsaIT Control: Once support for LDAPControls is complete 
I think we SHOULD drop l_ldap_manage_dsa_it() in LDAPObject.c and 
re-implement it completely in method 
ldap.ldapobject.LDAPObject.manage_dsa_it().

> I wouldn't turn down a mention at
> the bottom of the README file, though. :)

Already in CVS. Thanks again for working on it!

Ciao, Michael.



More information about the python-ldap mailing list