LegacyPasswordHasherInterface
extends
PasswordHasherInterface
in
Provides password hashing and verification capabilities for "legacy" hashers that require external salts.
Tags
Table of Contents
Constants
- MAX_PASSWORD_LENGTH = 4096
Methods
- hash() : string
- Hashes a plain password.
- needsRehash() : bool
- Checks if a password hash would benefit from rehashing.
- verify() : bool
- Checks that a plain password and a salt match a password hash.
Constants
MAX_PASSWORD_LENGTH
public
mixed
MAX_PASSWORD_LENGTH
= 4096
Methods
hash()
Hashes a plain password.
public
hash(string $plainPassword[, string $salt = null ]) : string
Parameters
- $plainPassword : string
- $salt : string = null
Tags
Return values
stringneedsRehash()
Checks if a password hash would benefit from rehashing.
public
needsRehash(string $hashedPassword) : bool
Parameters
- $hashedPassword : string
Return values
boolverify()
Checks that a plain password and a salt match a password hash.
public
verify(string $hashedPassword, string $plainPassword[, string $salt = null ]) : bool
Parameters
- $hashedPassword : string
- $plainPassword : string
- $salt : string = null