| Crates.io | x509_lint |
| lib.rs | x509_lint |
| version | 0.2.0 |
| created_at | 2025-01-29 15:32:30.93144+00 |
| updated_at | 2025-01-30 14:32:36.194489+00 |
| description | X.509 linter (RFC 5280 certificates and CRLs) |
| homepage | https://github.com/chifflier/x509-lint |
| repository | https://github.com/chifflier/x509-lint.git |
| max_upload_size | |
| id | 1534921 |
| size | 54,041 |
x509-lint is a X.509 Certificates and Certificate Revocation List linter written in Rust.
It runs a set of checks, taken from
RFC5280 and other sources.
This repository provides both the command-line tool (x509lint)
and a Rust library (x509_lint) which can be
embeded in other Rust programs to use either the included lints, or custom ones.
x509lint binary toolCompile and install x509lint:
$ cargo install x509lint
Run the binary to display lint warnings and errors on certificates:
$ x509lint issuerFieldMissing.pem
Subject: C=US, ST=FL, L=Tallahassee, streetAddress=3210 Holly Mill Run, postalCode=30062, O=Extreme Discord, OU=Chaos, CN=gov.us
[error] The issuer field MUST contain a non-empty distinguished name (DN) citation:RFC5280: 4.1.2.4
The tool accepts input files in DER or PEM format.
x509_lint libraryUse cargo add or edit the cargo manifest Cargo.toml to add a dependency on x509_lint:
cargo add x509_lint
See x509_lint documentation for details on crate functions and examples.
The crate expects an object X509Certificate as input.
To parse DER or PEM certificate data and create an X509Certificate object, use the x509-parser crate.
x509-lint requires Rustc version 1.70.0 or greater
See CHANGELOG.md
Licensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.