PHP Forgot Password Function

后端 未结 12 883
后悔当初
后悔当初 2020-12-07 08:33

I have a small community website and I need to implement some sort of forgotten password function. I currently store the passwords in the DB, encrypted with MD5.

Is

12条回答
  •  天涯浪人
    2020-12-07 08:53

    As Marcus Reed stated, in 2015/2016 if you have PHP version >=5.5 don't use MD5, password_hash() and password_verify() provide an easy and secure hashing for your password with the ability to provide a cost and automatically salts the hash.

    I don't have the ability to vote or comment currently which is why I'm providing a definitive statement to avoid confusion.

提交回复
热议问题