Used charset in ldap tree

Frank Matthieß frankm at lug-owl.de
Thu Jul 21 14:26:52 CEST 2005


Dieter Kluenter [2005-07-20 18:48 CEST]:
> Frank Matthieß <frankm at lug-owl.de> writes:
> 
> > Dieter Kluenter [2005-07-20 16:13 CEST]:
> >> Frank Matthieß <frankm at lug-owl.de> writes:
> > [...]
> >> 
> 
> > Thanks for explaning this in detail.
> >
> > Ok. So i translate an iso-8859-15 ldif file to an utf-8 encoded file and
> > should encode the values with special characters with base64 too.
> 
> No, if you want to add or modify entries by means of an ldif file, you
> just convert iso8859-15 to UTF-8. The tool iconv is quite handy for
> this purpose. iconv -f iso8859-15 -t utf-8 -o myfile-utf-8.txt myfile.txt

Thanks for the hint to iconv.

Now i tried this: iso-8859-15

$ /kolab/bin/ldapadd -D "cn=manager,cn=internal,dc=bsv,dc=lan" -W -f testimport.ldif
Enter LDAP Password:
adding new entry "cn=Süd, Afrika,cn=external,dc=bsv,dc=lan"
ldap_add: Invalid DN syntax (34)
        additional info: invalid DN

This: utf-8

$ /kolab/bin/ldapadd -D "cn=manager,cn=internal,dc=bsv,dc=lan" -W -f testimport.ldif.u8
Enter LDAP Password:
adding new entry "cn=Süd, Afrika,cn=external,dc=bsv,dc=lan"
ldap_add: Invalid DN syntax (34)
        additional info: invalid DN

And this: utf-8 base64 encoded values

$ /kolab/bin/ldapadd -D "cn=manager,cn=internal,dc=bsv,dc=lan" -W -f testimport.ldif.u8.b64 
Enter LDAP Password: 
adding new entry "cn=Süd, Afrika,cn=external,dc=bsv,dc=lan"
ldap_add: Invalid DN syntax (34)
        additional info: invalid DN

$  file testimport.ldif testimport.ldif.u8 testimport.ldif.u8.b64
testimport.ldif:    ISO-8859 text
testimport.ldif.u8: UTF-8 Unicode text
testimport.ldif.u8.b64: UTF-8 Unicode text

The files:
testimport.ldif:
#  Süd, Afrika bsv.lan Lists/cn=Oeffentlich
dn: cn=Süd, Afrika,cn=external,dc=bsv,dc=lan
objectClass: top
objectClass: inetOrgPerson
objectClass: kolabInetOrgPerson
sn: Süd
cn: Süd, Afrika
givenName: Afrika
mail: mbox at mail.addr.tld

testimport.ldif.u8:
#  Süd, Afrika bsv.lan Lists/cn=Oeffentlich
dn: cn=Süd, Afrika,cn=external,dc=bsv,dc=lan
objectClass: top
objectClass: inetOrgPerson
objectClass: kolabInetOrgPerson
sn: Süd
cn: Süd, Afrika
givenName: Afrika
mail: mbox at mail.addr.tld

testimport.ldif.u8.b64:
# Süd, Afrika bsv.lan Lists/cn=Oeffentlich
dn:: Y249U8O8ZCwgQWZyaWthLGNuPWV4dGVybmFsLGRjPWJzdixkYz1sYW4=
objectClass: top
objectClass: inetOrgPerson
objectClass: kolabInetOrgPerson
sn:: Y249U8O8ZA==
cn:: Y249U8O8ZCwgQWZyaWth
givenName: Afrika
mail: mbox at mail.addr.tld

All three failed.

Any idea?

Frank.
-- 
Frank Matthieß

"Join the army - travel around - see many places - meet  interesting people....
 ... and kill them!" -- (resistance t-shirt)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.kolab.org/pipermail/users/attachments/20050721/20ede449/attachment.sig>


More information about the users mailing list