Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Release notes:
The main function of this crate has been incorporated into rustls-pki-types. 2.2.0 maintains the existing public API for this crate, on top of this new implementation. This drops the dependency on the
base64
crate, and allows for constant-time decoding of private keys.This crate will continue to exist in its current form, but it is somewhat unlikely that the API will be extended from its current state.
Should you wish to migrate to using the new
rustls-pki-types
PEM APIs directly, here is a rough cheat-sheet:CertificateDer
iteratorrustls_pemfile::certs(io::BufRead)
➡️
CertificateDer::pem_reader_iter(io::Read)
PrivateKeyDer
rustls_pemfile::private_key(io::BufRead)
➡️
PrivateKeyDer::from_pem_reader(io::Read)
CertificateSigningRequestDer
rustls_pemfile::csr(io::BufRead)
➡️
CertificateSigningRequestDer::from_pem_reader(io::Read)
CertificateRevocationListDer
iteratorrustls_pemfile::crls(io::BufRead)
➡️
CertificateRevocationListDer::pem_reader_iter(io::Read)
PrivatePkcs1KeyDer
iteratorrustls_pemfile::rsa_private_keys(io::BufRead)
➡️
PrivatePkcs1KeyDer::pem_reader_iter(io::Read)
PrivatePkcs8KeyDer
iteratorrustls_pemfile::pkcs8_private_keys(io::BufRead)
➡️
PrivatePkcs8KeyDer::pem_reader_iter(io::Read)
PrivateSec1KeyDer
iteratorrustls_pemfile::ec_private_keys(io::BufRead)
➡️
PrivateSec1KeyDer::pem_reader_iter(io::Read)
SubjectPublicKeyInfoDer
iteratorrustls_pemfile::public_keys(io::BufRead)
➡️
SubjectPublicKeyInfoDer::pem_reader_iter(io::Read)