PHPackages                             divineomega/laravel-password-exposed-validation-rule - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Security](/categories/security)
4. /
5. divineomega/laravel-password-exposed-validation-rule

Abandoned → [jord-jd/laravel-password-exposed-validation-rule](/?search=jord-jd%2Flaravel-password-exposed-validation-rule)Library[Security](/categories/security)

divineomega/laravel-password-exposed-validation-rule
====================================================

Laravel validation rule that checks if a password has been exposed in a data breach

v6.0.0(3mo ago)89699.2k↓12.6%413LGPL-3.0-onlyPHPPHP ^7.4||^8.0CI passing

Since Apr 26Pushed 3mo ago5 watchersCompare

[ Source](https://github.com/Jord-JD/laravel-password-exposed-validation-rule)[ Packagist](https://packagist.org/packages/divineomega/laravel-password-exposed-validation-rule)[ GitHub Sponsors](https://github.com/DivineOmega)[ RSS](/packages/divineomega-laravel-password-exposed-validation-rule/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (3)Versions (20)Used By (3)

🔒 Laravel Password Exposed Validation Rule
==========================================

[](#-laravel-password-exposed-validation-rule)

This package provides a Laravel validation rule that checks if a password has been exposed in a data breach. It uses the haveibeenpwned.com passwords API via the [`jord-jd/password_exposed`](https://github.com/Jord-JD/password_exposed) library.

```
// composer require jord-jd/laravel-password-exposed-validation-rule

use JordJD\LaravelPasswordExposedValidationRule\PasswordNotExposed;

$request->validate([
    'password' => ['required', new PasswordNotExposed()],
]);
```

Compatibility
-------------

[](#compatibility)

- PHP: 7.4+ and 8.x
- Laravel: 8.x through 12.x

Installation
------------

[](#installation)

To install, just run the following Composer command.

```
composer require jord-jd/laravel-password-exposed-validation-rule

```

Please note that this package requires Laravel 8.0 or above.

Usage
-----

[](#usage)

The following code snippet shows an example of how to use the password exposed validation rule.

```
use JordJD\LaravelPasswordExposedValidationRule\PasswordNotExposed;

$request->validate([
    'password' => ['required', new PasswordNotExposed()],
]);
```

If you wish, you can also set a custom validation message, as shown below.

```
use JordJD\LaravelPasswordExposedValidationRule\PasswordNotExposed;

$request->validate([
    'password' => ['required', (new PasswordNotExposed())->setMessage('This password is not secure.')],
]);
```

Backward Compatibility
----------------------

[](#backward-compatibility)

`PasswordExposed` remains available as a backwards-compatible alias for `PasswordNotExposed`.

Testing / Mocking
-----------------

[](#testing--mocking)

If you need deterministic tests, you can inject a checker directly or use a resolver.

```
use JordJD\LaravelPasswordExposedValidationRule\PasswordNotExposed;
use JordJD\PasswordExposed\Interfaces\PasswordExposedCheckerInterface;

$fakeChecker = new class implements PasswordExposedCheckerInterface {
    // Implement interface methods for your test scenario...
};

PasswordNotExposed::resolvePasswordExposedCheckerUsing(function () use ($fakeChecker) {
    return $fakeChecker;
});
```

###  Health Score

63

—

FairBetter than 99% of packages

Maintenance82

Actively maintained with recent releases

Popularity52

Moderate usage in the ecosystem

Community26

Small or concentrated contributor base

Maturity77

Established project with proven stability

 Bus Factor1

Top contributor holds 80.6% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~158 days

Recently: every ~353 days

Total

19

Last Release

92d ago

Major Versions

v1.2.3 → v2.0.02019-02-04

v2.5.0 → v4.0.02026-02-14

v4.0.0 → v5.0.02026-02-14

v5.0.1 → v6.0.02026-02-16

PHP version history (4 changes)v2.0.0PHP ^7.1

v2.4.0PHP ^7.1||^8.0

v2.5.0PHP ^7.1||^8.0||8.1

v6.0.0PHP ^7.4||^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/c580cdf7c14898fff179cdfc1085892091d5d2f49d917873a12365af9ac77c93?d=identicon)[Jord-JD](/maintainers/Jord-JD)

---

Top Contributors

[![Jord-JD](https://avatars.githubusercontent.com/u/650645?v=4)](https://github.com/Jord-JD "Jord-JD (50 commits)")[![jameswilddev](https://avatars.githubusercontent.com/u/3138458?v=4)](https://github.com/jameswilddev "jameswilddev (6 commits)")[![SteJaySulli](https://avatars.githubusercontent.com/u/60765965?v=4)](https://github.com/SteJaySulli "SteJaySulli (3 commits)")[![janpio](https://avatars.githubusercontent.com/u/183673?v=4)](https://github.com/janpio "janpio (1 commits)")[![lloricode](https://avatars.githubusercontent.com/u/8251344?v=4)](https://github.com/lloricode "lloricode (1 commits)")[![mikemand](https://avatars.githubusercontent.com/u/745184?v=4)](https://github.com/mikemand "mikemand (1 commits)")

---

Tags

data-breachlaravellaravel-5-packagelaravel-validationpasswordsphpsecurity

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/divineomega-laravel-password-exposed-validation-rule/health.svg)

```
[![Health](https://phpackages.com/badges/divineomega-laravel-password-exposed-validation-rule/health.svg)](https://phpackages.com/packages/divineomega-laravel-password-exposed-validation-rule)
```

###  Alternatives

[illuminate/encryption

The Illuminate Encryption package.

9229.7M280](/packages/illuminate-encryption)[spatie/laravel-ciphersweet

Use ciphersweet in your Laravel project

416718.4k1](/packages/spatie-laravel-ciphersweet)[ercsctt/laravel-file-encryption

Secure file encryption and decryption for Laravel applications

642.6k](/packages/ercsctt-laravel-file-encryption)[dgtlss/owaspadvisor

A Laravel package to help developers implement OWASP Top 10 security guidelines

327.1k](/packages/dgtlss-owaspadvisor)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
