Hasher

interface Hasher (View source)

Methods

string make(string $value, array $options = [])

Hash the given value.

bool check(string $value, string $hashedValue, array $options = [])

Check the given plain value against a hash.

bool needsRehash(string $hashedValue, array $options = [])

Check if the given hash has been hashed using the given options.

Details

string make(string $value, array $options = [])

Hash the given value.

Parameters

string $value
array $options

Return Value

string

bool check(string $value, string $hashedValue, array $options = [])

Check the given plain value against a hash.

Parameters

string $value
string $hashedValue
array $options

Return Value

bool

bool needsRehash(string $hashedValue, array $options = [])

Check if the given hash has been hashed using the given options.

Parameters

string $hashedValue
array $options

Return Value

bool

© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/5.5/Illuminate/Contracts/Hashing/Hasher.html