Skip to content

Commit 0f37efe

Browse files
committed
Prepare 2.2.0
1 parent f5d49b2 commit 0f37efe

File tree

3 files changed

+26
-2
lines changed

3 files changed

+26
-2
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "rustls-pemfile"
3-
version = "2.1.3"
3+
version = "2.2.0"
44
edition = "2018"
55
license = "Apache-2.0 OR ISC OR MIT"
66
readme = "README.md"

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,30 @@ poor and doing so doesn't address a meaningful threat model.
88
[![Crate](https://img.shields.io/crates/v/rustls-pemfile.svg)](https://crates.io/crates/rustls-pemfile)
99
[![Documentation](https://docs.rs/rustls-pemfile/badge.svg)](https://docs.rs/rustls-pemfile/)
1010

11+
# See also: rustls-pki-types
12+
13+
The main function of this crate has been incorporated into
14+
[rustls-pki-types](https://crates.io/crates/rustls-pki-types). 2.2.0 maintains the
15+
existing public API for this crate, on top of this new implementation. This drops
16+
the dependency on the `base64` crate, and allows for constant-time decoding of private keys.
17+
18+
This crate will continue to exist in its current form, but it is somewhat unlikely that the
19+
API will be extended from its current state.
20+
21+
Should you wish to migrate to using the new [`rustls-pki-types` PEM APIs](https://docs.rs/rustls-pki-types/latest/rustls_pki_types/pem/trait.PemObject.html)
22+
directly, here is a rough cheat-sheet:
23+
24+
| *Use case* | *Replace* |
25+
|---|---|
26+
| File stream to `CertificateDer` iterator |`rustls_pemfile::certs(io::BufRead)` <br> ➡️ <br> `CertificateDer::pem_reader_iter(io::Read)` |
27+
| File stream to one `PrivateKeyDer` | `rustls_pemfile::private_key(io::BufRead)` <br> ➡️ <br> `PrivateKeyDer::from_pem_reader(io::Read)` |
28+
| File stream to one `CertificateSigningRequestDer` | `rustls_pemfile::csr(io::BufRead)` <br> ➡️ <br> `CertificateSigningRequestDer::from_pem_reader(io::Read)` |
29+
| File stream to `CertificateRevocationListDer` iterator |`rustls_pemfile::crls(io::BufRead)` <br> ➡️ <br> `CertificateRevocationListDer::pem_reader_iter(io::Read)` |
30+
| File stream to `PrivatePkcs1KeyDer` iterator |`rustls_pemfile::rsa_private_keys(io::BufRead)` <br> ➡️ <br> `PrivatePkcs1KeyDer::pem_reader_iter(io::Read)` |
31+
| File stream to `PrivatePkcs8KeyDer` iterator |`rustls_pemfile::pkcs8_private_keys(io::BufRead)` <br> ➡️ <br> `PrivatePkcs8KeyDer::pem_reader_iter(io::Read)` |
32+
| File stream to `PrivateSec1KeyDer` iterator |`rustls_pemfile::ec_private_keys(io::BufRead)` <br> ➡️ <br> `PrivateSec1KeyDer::pem_reader_iter(io::Read)` |
33+
| File stream to `SubjectPublicKeyInfoDer` iterator |`rustls_pemfile::public_keys(io::BufRead)` <br> ➡️ <br> `SubjectPublicKeyInfoDer::pem_reader_iter(io::Read)` |
34+
1135
# Changelog
1236

1337
The detailed list of changes in each release can be found at

0 commit comments

Comments
 (0)