class NotPwnedVerifier implements UncompromisedVerifier

Methods

__construct(Factory $factory, int $timeout = 30)

Create a new uncompromised verifier.

bool
verify(array $data)

Verify that the given data has not been compromised in public breaches.

array
getHash(string $value)

Get the hash and its first 5 chars.

search(string $hashPrefix)

Search by the given hash prefix and returns all occurrences of leaked passwords.

Details

at line 21
__construct(Factory $factory, int $timeout = 30)

Create a new uncompromised verifier.

Parameters

Factory $factory

the HTTP factory instance

int $timeout

the number of seconds the request can run before timing out

at line 30
bool verify(array $data)

Verify that the given data has not been compromised in public breaches.

Parameters

array $data

Return Value

bool

at line 52
protected array getHash(string $value)

Get the hash and its first 5 chars.

Parameters

string $value

Return Value

array

Search by the given hash prefix and returns all occurrences of leaked passwords.

Parameters

string $hashPrefix

Return Value

Collection