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

Re: ldif import problems



Quoting Kevin Reck <reck@admin.uwex.edu>:

> I am trying to import my ldif file.. but the userPassword field keeps
> getting imported wrong.  No matter what I put into the userPassword
> field openLDAP stores it incorrectly.
> 
> I tried
> userPassword: test
> 
> and when I do a ldapsearch it comes back as
> 
> userPassword:: dGVzdCA=

Couple of ideas.

What you see is the MIME Base64 encoding of the password.  This 
is not encrypted -- instead, it's a way of storing non-ASCII
characters.  This suggests that something you're feeding the
LDAPADD command (I assume this is what you used) is unexpected,
forcing it to encode it in self-defence.  This sometimes occurs
if there is either a space AFTER the password, or if you're
using non-UNIX line endings, e.g., CR/LF instead of just LF.

One way to check what's exactly there is with the Linux command:

od -bc infile.ldif | more

Then inspect your input data to see what's really there.

Another option -- maybe the Open LDAP requires that field to 
always be encoded with your schema, but I don't know how to do
(or undo) this.

Hope that helps!

*********************************
        Paul Gillingwater
        Managing Director
 CSO Lanifex Unternehmensberatung 
 & Softwareentwicklung G.m.b.H.
      NEW BUSINESS CONCEPTS

E-mail:  paul@lanifex.com
Teleph:  +43(1)2198222-0
Fax:     +43(1)2198222-11
Mobile:  +43(699)1922 3085
Webhome: http://www.lanifex.com/
Address: Praterstrasse 60/1/2 
         A-1020 Vienna, Austria
*********************************