From 60a22b1a3f112e6470d44766693597fb077a9a0f Mon Sep 17 00:00:00 2001 From: Tony Arcieri Date: Sun, 14 Nov 2021 14:20:33 -0700 Subject: [PATCH] pkcs8: rename `Error::EncryptedKey` => `::EncryptedPrivateKey` More consistent with the rest of the type names --- pkcs8/src/error.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkcs8/src/error.rs b/pkcs8/src/error.rs index b433bb7c1..6fa015081 100644 --- a/pkcs8/src/error.rs +++ b/pkcs8/src/error.rs @@ -14,7 +14,7 @@ pub enum Error { /// Errors relating to PKCS#5-encrypted keys. #[cfg(feature = "pkcs5")] - EncryptedKey(pkcs5::Error), + EncryptedPrivateKey(pkcs5::Error), /// Malformed cryptographic key contained in a PKCS#8 document. /// @@ -36,7 +36,7 @@ impl fmt::Display for Error { match self { Error::Asn1(err) => write!(f, "PKCS#8 ASN.1 error: {}", err), #[cfg(feature = "pkcs5")] - Error::EncryptedKey(err) => write!(f, "{}", err), + Error::EncryptedPrivateKey(err) => write!(f, "{}", err), Error::KeyMalformed => f.write_str("PKCS#8 cryptographic key data malformed"), Error::ParametersMalformed => f.write_str("PKCS#8 algorithm parameters malformed"), Error::PublicKey(err) => write!(f, "public key error: {}", err), @@ -62,7 +62,7 @@ impl From for Error { #[cfg(feature = "pkcs5")] impl From for Error { fn from(err: pkcs5::Error) -> Error { - Error::EncryptedKey(err) + Error::EncryptedPrivateKey(err) } }