From: <mi...@st...> - 2005-05-04 05:41:54
|
Ingo Steuwer wrote: > > modlist=[(ldap.MOD_REPLACE,"description",[u"hallöle".encode('ISO-8859-1')])] > lo.modify_s("CN=moreusers,CN=Users,%s"%ldap_base,modlist) LDAPv3 mandates use of Unicode with UTF-8 encoding. You are accessing Active Directory via its LDAPv3 interface. Hence it expects UTF-8. > It is documented that Active Directory uses ISO-8859-1 and not utf8 (like > Openldap an others). I doubt that. Well, depends on what "Active Directory uses ISO-8859-1" really means... But the charset of the internal storage of AD is not relevant when accessing it through LDAPv3. > So, is this a python-ldap or openldap-problem Nope. The applications using python-ldap are responsible to provide the proper charset and encoding at the API level. > (I know, great chanceto start an AD-Flamewar)? (Not at all.) > Any experiences/solutions? I've tried it. It works for me with UTF-8. Ciao, Michael. |