简体   繁体   中英

how to compare a user entered password to an encrypted password in a database using BCrypt

I have a task where I need to verify a users password using BCrypt before they can retrieve their transaction details out of a database, the password for the account has already been hashed and put into the database. I am new to BCrypt and I have no idea where to begin. I just need some help understanding how BCrypt works and also I need to know how to compare a user entered password (via an Input Box) to an encrypted password in a database so that the user can retrieve their information.

I am new to BCrypt and I have no idea where to begin

This can be a good start. read the details here

I just need some help understanding how BCrypt works

A .Net port of jBCrypt implemented in C#. It uses a variant of the Blowfish encryption algorithm's keying schedule, and introduces a work factor, which allows you to determine how expensive the hash function will be, allowing the algorithm to be "future-proof".

I need to know how to compare a user entered password (via an Input Box) to an encrypted password in a database so that the user can retrieve their information.

This article contains a full example of how to do that.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM