change password for user

Jan-Frode Myklebust janfrode at
Sun Mar 8 00:44:43 CET 2009

I have a script that tries to sync a userdatabase with
plaintext username/password in mysql, to a Centos Directory
Server. Currently I've been pushing the passwords into the
directory by first creating the SSHA1 hash in python and
store '{SSHA}' + encode-string in the password field.

But, it occurred to me that I'm not fully sure what I'm doing 
when creating the SSHA1 hash, so it would be nice to have
the directory server do the hashing instead. I've found the

	passwd_s(user, oldpw, newpw, [serverctrls=None, [clientctrls=None]])

but are there any way to use that when I don't know the plaintext
'oldpw' ?


More information about the python-ldap mailing list