Hi, all.
How can i add a booleanMatch type attribute with py-ldap?
Refer to python-ldap-2.3.10/Demo/ldapcontrols.py, i use below code to add new
attribute:
----
l = ldap.initialize('ldap://localhost:389',trace_level=2)
l.add_ext_s(dn, modlist, serverctrls=[
BooleanControl('1.3.6.1.4.1.4203.1.10.1',1,1) ],)
----
But i got this error message:
----
=> result: 2
*** ldap://127.0.0.1:389/ - SimpleLDAPObject.result3 ((2, 1, -1),{})
=> LDAPError - UNAVAILABLE_CRITICAL_EXTENSION: {'info': 'critical extension is
not recognized', 'desc': 'Critical extension is unavailable'}
----
I use amavisd-new attribute:
----
attributetype ( 1.3.6.1.4.1.15312.2.2.1.19
NAME 'amavisLocal'
DESC 'Is user considered local'
EQUALITY booleanMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.7
SINGLE-VALUE )
----
--
Best Regards.
Zhang Huangbin
- Open Source Mail Server Solution for Red Hat(R) Enterprise Linux,
CentOS, Debian, Ubuntu, FreeBSD: http://www.iredmail.org/
------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Python-LDAP-dev mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/python-ldap-dev