BcryptPasswordHashingStrategy

BcryptPasswordHashingStrategy

A hashing strategy which uses bcrypt (https://en.wikipedia.org/wiki/Bcrypt) to hash plaintext password strings.

Signature

class BcryptPasswordHashingStrategy implements PasswordHashingStrategy {
  hash(plaintext: string) => Promise<string>;
  check(plaintext: string, hash: string) => Promise<boolean>;
}

Implements

Members

hash

method
type:
(plaintext: string) => Promise<string>

check

method
type:
(plaintext: string, hash: string) => Promise<boolean>