View Source Bcrypt.Base (bcrypt_elixir v3.0.0)
Base module for the Bcrypt password hashing library.
Link to this section Summary
Functions
Verify the password by comparing it with the stored hash.
Generate a salt for use with the hash_password
function.
Generate a salt for use with Bcrypt.
Hash the password and salt with the Bcrypt hashing algorithm.
Hash a password using Bcrypt.
Link to this section Functions
Verify the password by comparing it with the stored hash.
Generate a salt for use with the hash_password
function.
The :log_rounds
parameter determines the computational complexity
of the generation of the password hash. Its default is 12, the minimum is 4,
and the maximum is 31.
The :legacy
option is for generating salts with the old $2a$
prefix.
Only use this option if you need to generate hashes that are then checked
by older libraries.
Generate a salt for use with Bcrypt.
Hash the password and salt with the Bcrypt hashing algorithm.
Hash a password using Bcrypt.