Migrate old md5 passwords to bcrypt passwords

前端 未结 4 429
耶瑟儿~
耶瑟儿~ 2020-12-28 08:09

I\'m reworking a website in Rails using Devise for authentication. The previous website works with a database of users with md5 passwords, and therefore I want to migrate th

4条回答
  •  遥遥无期
    2020-12-28 08:37

    You will have to ask the user to login using the old password and then change it for example show a compulsory change password page which will store the password using bcrypt. Once the new password is given you could disable/delete the old password in you system.

提交回复
热议问题