[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: API for assertion control

Michael Ströder wrote:

I'd like to implement the assertion control in python-ldap.

Are there already any utility functions usable for generating the control value? Basically this would be turning a filter string representation into the BER. Yes?

Preferrably in OpenLDAP 2.3.x libs (since 2.3 is currently the minimum requirement for building python-ldap).

AFAIK, there's none. You could easily implement one by moving the code available in clients/tools/common.c into a specific (non-existing yet) libraries/libldap/assertion.c file that implements the control manipulation along the lines already set for other well-known controls; see libraries/libldap/ppolicy.c or similar for guidelines. You ought to create some

	int ldap_create_assertion_control(LDAP *ld, LDAPControl **ctrlp,
		char *filter, int iscritical)

function. Please provide a patch using the ITS (or commit it, if you feel comfortable with it). If you feel uncomfortable, just submit a feature request with the ITS.


Ing. Pierangelo Masarati OpenLDAP Core Team

SysNet s.r.l.
via Dossi, 8 - 27100 Pavia - ITALIA
Office:  +39 02 23998309
Mobile:  +39 333 4963172
Email:   ando@sys-net.it