From 6342853a870080a4f4c9f7577c2cd383687aac70 Mon Sep 17 00:00:00 2001 From: Jason Heath Date: Thu, 23 Mar 2023 08:20:22 -0400 Subject: [PATCH] Bump pem from 1.1.1 to 2.0.0 Bumps [pem](https://github.com/jcreekmore/pem-rs) from 1.1.1 to 2.0.0. - [Release notes](https://github.com/jcreekmore/pem-rs/releases) - [Changelog](https://github.com/jcreekmore/pem-rs/blob/master/CHANGELOG.md) - [Commits](https://github.com/jcreekmore/pem-rs/compare/v1.1.1...v2.0.0) --- updated-dependencies: - dependency-name: pem dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] - pem made struct fields private and added wrappers so needed to update a call - dropped the borrow per clippy Signed-off-by: Jason Heath --- Cargo.lock | 16 +++++++++++++--- .../core/src/tls/native_tls_wrapper/readers.rs | 2 +- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 83bdbb3579..ca302be885 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1450,7 +1450,7 @@ dependencies = [ "num_cpus", "os_info", "paste", - "pem", + "pem 2.0.0", "pin-project", "rand 0.8.5", "rcgen", @@ -1487,7 +1487,7 @@ dependencies = [ "httparse", "log 0.4.17", "native-tls", - "pem", + "pem 2.0.0", "reqwest", "serde", "serde_json", @@ -2581,6 +2581,16 @@ dependencies = [ "base64 0.13.1", ] +[[package]] +name = "pem" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "31687a56a7298a78519d971a1dfeee8e08d8e6bf9407b9233c985538c79e1123" +dependencies = [ + "base64 0.21.0", + "serde", +] + [[package]] name = "percent-encoding" version = "2.2.0" @@ -2962,7 +2972,7 @@ version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ffbe84efe2f38dea12e9bfc1f65377fdf03e53a18cb3b995faedf7934c7e785b" dependencies = [ - "pem", + "pem 1.1.1", "ring", "time 0.3.11", "yasna", diff --git a/components/core/src/tls/native_tls_wrapper/readers.rs b/components/core/src/tls/native_tls_wrapper/readers.rs index 2caff2f15b..39a2fa69e6 100644 --- a/components/core/src/tls/native_tls_wrapper/readers.rs +++ b/components/core/src/tls/native_tls_wrapper/readers.rs @@ -132,7 +132,7 @@ fn certs_from_pem_file(buf: &[u8]) -> Result> { // rest. Certificate::from_pem(buf)?; pem::parse_many(buf)?.iter() - .map(|cert| Ok(Certificate::from_der(&cert.contents)?)) + .map(|cert| Ok(Certificate::from_der(cert.contents())?)) .collect() }