I have an encrypted password md5, how to give a password to the user when he uses the "Forgot password"?

I have a database entry for a password in md5 format, but when a user uses "Forgot password", then how can I give him / her the desired password?

+5
source share
5 answers

You cannot do this from the MD5 hash; and you cannot do it. Password recovery should be intractable.

The usual process is to send the reset password token (URL) to your email address so that the user can select a new password.

+12
source

- MD5 - "" - , .

, :

  • reset. ( , .) reset - , .. (: .)

  • , reset, , ( / , , "0", "o", "O" .. ), , , .

, .

+3

, , , . , reset .

+2

you need to send to the new passworduser and then install in the database. otherwise, the original password may not be restored.

Thank.

+2
source

You have a 1/100 chance to recover this password (dictionary method) based on the length of the password. I will not recommend it.

It is better to create a new random password and send it to the user's email address.

+1
source

All Articles