A couple of questions. By storing nonce in the database, you completely destroy the nonce value and therefore weaken the overall security of the application. By preserving the salt, you also weaken security, because if I get access to the database, I know the "random" value of the salt that you used for the account, so opening up attacks on rainbow tables.
When a user submits this form ...
Retrieve $hash from the URL Recreate $nonce = hash($email . $key) Use $nonce to retrieve $salt from our table (if unexpired). If hash($salt . $email . $key) == $hash from URL, then the Validation is GOOD!, so we... Update the user password in the database Otherwise, we refuse the attempt to change the password
The foregoing is violated. Since I know that you store nonces, you reduced the security of your application, and then, while maintaining salt, also weakened security. Given the above scenario, I can get salt and output nonce if I have an email + hash algorithm (you should assume that I know your algorithm). Therefore, I can "quickly" break the entire database.
source share