PHPackages                             rollerworks/x509-validator - 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. [Validation &amp; Sanitization](/categories/validation)
4. /
5. rollerworks/x509-validator

ActiveLibrary[Validation &amp; Sanitization](/categories/validation)

rollerworks/x509-validator
==========================

X509 PEM-encoded validators. CA-Chain, OCSP, common-name compatibility, purpose

v0.3.1(1y ago)0691[2 issues](https://github.com/rollerworks/X509Validator/issues)1MITPHPPHP ^8.2CI passing

Since Nov 27Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/rollerworks/X509Validator)[ Packagist](https://packagist.org/packages/rollerworks/x509-validator)[ RSS](/packages/rollerworks-x509-validator/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (6)Dependencies (15)Versions (7)Used By (1)

Rollerworks X509Validator
=========================

[](#rollerworks-x509validator)

This package provides X509 TLS certificate/private-key validators to validate the following:

- CA chain completeness
- PrivateKey bits length
- Signature algorithm
- OCSP Revocation status (requires internet access)
- Certificate purpose
- Certificate general validity (private-key compatibility, not expired, readable)
- Certificate hostname pattern supported, and protection against global wildcards of public-suffix length violations

**Tip:** Violations can be easily translated using the Symfony Translator component and provided translations.

Use the [X509Validator Symfony Constraints](https://github.com/rollerworks/X509Validator-symfony) (separate package) to these validators with the Symfony Validator component.

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

[](#installation)

To install this package, add `rollerworks/x509-validator` to your composer.json:

```
php composer.phar require rollerworks/x509-validator
```

Now, [Composer](https://getcomposer.org/doc/00-intro.md) will automatically download all required files, and install them for you.

Requirements
------------

[](#requirements)

You need at least PHP 8.2, internet access is required if you want to validate a certificate's OCSP status.

Basic Usage
-----------

[](#basic-usage)

The `CertificateValidator` and `KeyValidator` are to primary validators for validating a certificate or private-key encoded in PEM (base64), DER (binary) is not supported.

See [documentation](docs/index.md) for usage of all validators.

Versioning
----------

[](#versioning)

For transparency and insight into the release cycle, and for striving to maintain backward compatibility, this package is maintained under the Semantic Versioning guidelines as much as possible.

Releases will be numbered with the following format:

`..`

And constructed with the following guidelines:

- Breaking backward compatibility bumps the major (and resets the minor and patch)
- New additions without breaking backward compatibility bumps the minor (and resets the patch)
- Bug fixes and misc changes bumps the patch

For more information on SemVer, please visit .

License
-------

[](#license)

This library is released under the [MIT license](LICENSE).

Contributing
------------

[](#contributing)

This is an open source project. If you'd like to contribute, please read the [Contributing Guidelines](https://contributing.rollerscapes.net/). If you're submitting a pull request, please follow the guidelines in the [Submitting a Patch](https://contributing.rollerscapes.net/latest/patches.html) section.

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance64

Regular maintenance activity

Popularity9

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~110 days

Recently: every ~132 days

Total

6

Last Release

397d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f0e812c04e848e9cc3afe6e966d2b81e81308124d96ce5f54eff4db0f8db0ea9?d=identicon)[sstok](/maintainers/sstok)

---

Top Contributors

[![sstok](https://avatars.githubusercontent.com/u/904790?v=4)](https://github.com/sstok "sstok (29 commits)")

---

Tags

validatorx509tlssslocsp

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/rollerworks-x509-validator/health.svg)

```
[![Health](https://phpackages.com/badges/rollerworks-x509-validator/health.svg)](https://phpackages.com/packages/rollerworks-x509-validator)
```

###  Alternatives

[symfony/validator

Provides tools to validate values

2.7k306.4M4.1k](/packages/symfony-validator)[symfony/symfony

The Symfony PHP framework

31.4k87.2M2.2k](/packages/symfony-symfony)[api-platform/core

Build a fully-featured hypermedia or GraphQL API in minutes!

2.6k51.2M339](/packages/api-platform-core)[respect/validation

The most awesome validation engine ever created for PHP

6.0k39.9M415](/packages/respect-validation)[seld/jsonlint

JSON Linter

1.3k228.7M271](/packages/seld-jsonlint)[composer/spdx-licenses

SPDX licenses list and validation library.

1.4k193.5M40](/packages/composer-spdx-licenses)

PHPackages © 2026

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