[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: International characters (OpenLDAP v2.0, PHP 4)
Hi,
On Tuesday 10 June 2003 08:55, Turbo Fredriksson wrote:
> The new LDIF I'm playing with is a user with the 'cn=Örjan Östlund'
> (just to get a national character). UTF8 encoding it will give me the
> following output from 'ldapadd':
>
> ----- s n i p -----
> adding new entry "uid=test2%bayour.com,o=Turbo Fredriksson"
> ldap_add: Invalid syntax
> additional info: givenname: value #0 invalid per syntax
> ----- s n i p -----
>
> And the LDIF looks like:
> ----- s n i p -----
> dn: uid=test2%bayour.com,o=Turbo Fredriksson
> uid: test2%bayour.com
> givenname: Ãrjan
> sn: Ãstlund
> accountstatus: active
> mail: test2@bayour.com
> uidnumber: 500
> gidnumber: 500
> gecos: Ãrjan Ãstlund
> cn: Ãrjan Ãstlund
> userpassword: {SHA}qUqP5cyxm6YcTAhz05Hph5gvu9M=
> homedirectory: /var/mail/users/test2%bayour.com
> mailhost: papadoc.bayour.com
> deliverymode: localdelivery
> mailmessagestore: /var/mail/users/test2%bayour.com
> objectclass: inetorgperson
> objectclass: pilotperson
> objectclass: posixaccount
> objectclass: qmailuser
> ----- s n i p -----
You have to distinguish between LDIF input to LDAP and other input to LDAP:
* With LDIF files you need to Base64-encode the UTF8-encoded values
and separate them with a double colon from the attribute name.
* Input in programs does not need Base64-encoding after UTF8-encoding
--
Peter Marschall
eMail: peter@adpm.de