Skip to content

A pure-Python x509 validation library based on pyca/cryptography

Notifications You must be signed in to change notification settings

alex/x509-validator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

x509-validator

WARNING: This has never received any sort of security review, don't use it.

This library is a pure-Python implementation of X.509 certificate path building and validation, built on top of pyca/cryptography.

Usage

from cryptography import x509

from validator import X509Validator, ValidationContext

validator = X509Validator([list-of-trusted-x509-certificates])
validator.validate(
    leaf_certificate
    ValidationContext(
        name=x509.DNSName(hostname),
        extra_certs=[list-of-intermediate-x509-certificates],
        extended_key_usage=x509.ExtendedKeyUsageOIDs.SERVER_AUTH,
    )
)

Will return the built chain on success, or raise an x509.ValidationError on failure.

Work in progress

See the issue tracker for things that are currently known to be unimplemented (seek existential assistance for things that are not known to be unimplemented).

About

A pure-Python x509 validation library based on pyca/cryptography

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages