This package provides a Laravel validation rule that checks if a password has been exposed in a data breach.
To install, just run the following Composer command.
composer require divineomega/laravel-password-exposed-validation-rule
Please note that this package requires Laravel 5.1 or above.
The following code snippet shows an example of how to use the password exposed validation rule.
use DivineOmega\LaravelPasswordExposedValidationRule\PasswordExposed;
$request->validate([
'password' => ['required', new PasswordExposed],
]);
It is also worth noting that due to the underlying API calls, your environment will need a working SSL certificate