darookee/pwnwedpassword-validator

PwnedPassword Validator Constraint for Symfony

Maintainers

Package info

github.com/darookee/pwnwedpassword-validator

pkg:composer/darookee/pwnwedpassword-validator

Statistics

Installs: 478

Dependents: 0

Suggesters: 0

Stars: 2

Open Issues: 0

1.0.1 2018-11-23 16:19 UTC

This package is auto-updated.

Last update: 2026-03-08 01:52:12 UTC


README

This Validator uses curl to query the https://haveibeenpwned.com API for the first 5 chars of the SHA1 of a value, that is to be validated. If it finds the exact SHA1 hash in the response it will add a validation error.

Usage

use R\Validator\Constraints as RAssert;

class MyEntity {

    /**
    * @RAssert\PwnedPasswords()
    **/
    var $password;
}