Hi,

I'm writing a script to help my fellow admins automatically creates user
 accounts in OpenLDAP 2.4. I can provide copy of script if you would 
like it.

The issue I have is encrypting the plain text word into passwd format, I found 
the very helpful slappasswd2.4 which seems to work so I put it into my script:


echo $NEWPASS > /tmp/newpass
chmod 400 /tmp/newpass
slappasswd2.4 -h {crypt} -T /tmp/newpass > /tmp/passenc
chmod 400 /tmp/passenc
EPASS=`cat /tmp/passenc`

It creates an entry in the passenc file which looks like this:


{crypt}mHUqpeNah1BOQ

But when i use this as a variable to the 'userpassword:' attribute then try to 
compare passwds within phpLDAPadmin (1.2.0.5) it fails.

The
 phpLDAPadmin encryption uses random Salt (AKA SaltedHash), which I can 
disable, but would rather not. So how does I use the Crypt::SaltedHash to
 encrypt a plain text word? (or anything that does the trick really!)

Cheers,

Stuart.

                                          
_________________________________________________________________
http://clk.atdmt.com/UKM/go/197222280/direct/01/
Do you have a story that started on Hotmail? Tell us now
------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share 
of $1 Million in cash or HP Products. Visit us here for more details:
http://ad.doubleclick.net/clk;226879339;13503038;l?
http://clk.atdmt.com/CRS/go/247765532/direct/01/
_______________________________________________
phpldapadmin-users mailing list
phpldapadmin-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/phpldapadmin-users

Reply via email to