title: How to ReHash a password stored into my Database ? (PHP)
body: <p>I have some passwords encrypted in my database and I would like to find a way to display them. Here is how they are saved into my mysql database:</p>
  
  <pre><code>function generateHash($plainText, $salt = null){
  
                  if ($salt === null)
    {
     $salt = substr(md5(uniqid(rand(), true)), 0, 25);
    }
    else
    {
     $salt = substr($salt, 0, 25);
    }
  
    return $salt . sha1($salt . $plainText);
   }
  
          $secure_pass = generateHash($this-&gt;clean_password);
  </code></pre>
  
  <p>Then $secure_pass is saved into my database.</p>
  
  <p>Anyone would have an idea ??</p>
  
  <p>Thank you very much ;)</p>