Issue #699 has been updated by Clément OUDOT.

Status changed from New to Assigned
Assigned to set to Clément OUDOT
Target version changed from self-service-password-? to self-service-password-0.9


----------------------------------------
Feature #699: set hash type based on stored password
http://tools.lsc-project.org/issues/699

Author: alex p
Status: Assigned
Priority: Normal
Assigned to: Clément OUDOT
Category: Self Service Password
Target version: self-service-password-0.9


It's sometimes useful to set hash type based on the stored password (i.e. some 
passwords stored in cleartext, some in ssha).
When stored password is cleatext it will be cleartext after changing, and if it 
is ssha it would be ssha after changing.

In the code it would be something like this:

  
<pre>
    $searchUserPass = 
ldap_search($ldap,$userdn,"(objectClass=*)",array("userPassword")) or 
die("error");
    $storedHash = ldap_get_values($ldap, 
ldap_first_entry($ldap,$searchUserPass), "userPassword");

    if (strpos(strtolower($storedHash[0]),"{".strtolower($hash)."}") === false) 
{
        $hash = "clear";
    }

</pre>




-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://tools.lsc-project.org/my/account
_______________________________________________
ltb-dev mailing list
[email protected]
http://lists.ltb-project.org/listinfo/ltb-dev

Reply via email to