How to decrypt hash stored by bcrypt

前端 未结 5 1412
我寻月下人不归
我寻月下人不归 2020-12-13 00:37

I have this script that encrypts a password but I don\'t know how to reverse it and decrypt it. This may be a very simple answer but I don\'t understand how to do it.

<
5条回答
  •  爱一瞬间的悲伤
    2020-12-13 00:57

    You simply can't.

    bcrypt uses salting, of different rounds, I use 10 usually.

    bcrypt.hash(req.body.password,10,function(error,response){ }
    

    This 10 is salting random string into your password.

提交回复
热议问题