Fully Qualified Name: | Laminas\Crypt\Password\BcryptSha |
Extends: | Bcrypt |
Bcrypt algorithm using crypt() function of PHP with password hashed using SHA2 to allow for passwords >72 characters.
Name | Description | Defined By |
---|---|---|
__construct() | Constructor | Bcrypt |
benchmarkCost() | Bcrypt | |
create() | BcryptSha | BcryptSha |
getCost() | Get the cost parameter | Bcrypt |
getSalt() | Get the salt value | Bcrypt |
setCost() | Set the cost parameter | Bcrypt |
setSalt() | Set the salt value | Bcrypt |
verify() | Verify if a password is correct against a hash value | BcryptSha |
Constructor
Parameter Name | Type | Description |
---|---|---|
$options | array|\Traversable |
Returns:
Parameter Name | Type | Description |
---|---|---|
$timeTarget |
Returns: void
BcryptSha
Parameter Name | Type | Description |
---|---|---|
$password | string |
Returns: string
Get the cost parameter
Returns: string
Get the salt value
Returns: string
Set the cost parameter
Parameter Name | Type | Description |
---|---|---|
$cost | int|string |
Returns: \Bcrypt Provides a fluent interface
Set the salt value
Parameter Name | Type | Description |
---|---|---|
$salt | string |
Returns: \Bcrypt Provides a fluent interface
Verify if a password is correct against a hash value
Parameter Name | Type | Description |
---|---|---|
$password | string | |
$hash | string |
Returns: bool