pub struct EncryptedPrivateKeyInfo<'a> {
pub encryption_algorithm: EncryptionScheme<'a>,
pub encrypted_data: &'a [u8],
}Available on crate feature
pkcs5 only.Expand description
PKCS#8 EncryptedPrivateKeyInfo.
ASN.1 structure containing a PKCS#5 EncryptionScheme identifier for a
password-based symmetric encryption scheme and encrypted private key data.
§Schema
Structure described in RFC 5208 Section 6:
EncryptedPrivateKeyInfo ::= SEQUENCE {
encryptionAlgorithm EncryptionAlgorithmIdentifier,
encryptedData EncryptedData }
EncryptionAlgorithmIdentifier ::= AlgorithmIdentifier
EncryptedData ::= OCTET STRINGFields§
§encryption_algorithm: EncryptionScheme<'a>Algorithm identifier describing a password-based symmetric encryption
scheme used to encrypt the encrypted_data field.
encrypted_data: &'a [u8]Private key data
Implementations§
Source§impl<'a> EncryptedPrivateKeyInfo<'a>
impl<'a> EncryptedPrivateKeyInfo<'a>
Trait Implementations§
Source§impl<'a> Clone for EncryptedPrivateKeyInfo<'a>
impl<'a> Clone for EncryptedPrivateKeyInfo<'a>
Source§fn clone(&self) -> EncryptedPrivateKeyInfo<'a>
fn clone(&self) -> EncryptedPrivateKeyInfo<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for EncryptedPrivateKeyInfo<'a>
impl<'a> Debug for EncryptedPrivateKeyInfo<'a>
Source§impl<'a> DecodeValue<'a> for EncryptedPrivateKeyInfo<'a>
impl<'a> DecodeValue<'a> for EncryptedPrivateKeyInfo<'a>
Source§fn decode_value<R: Reader<'a>>(
reader: &mut R,
header: Header,
) -> Result<EncryptedPrivateKeyInfo<'a>>
fn decode_value<R: Reader<'a>>( reader: &mut R, header: Header, ) -> Result<EncryptedPrivateKeyInfo<'a>>
Attempt to decode this message using the provided
Reader.Source§impl EncodeValue for EncryptedPrivateKeyInfo<'_>
impl EncodeValue for EncryptedPrivateKeyInfo<'_>
Source§impl<'a> PartialEq for EncryptedPrivateKeyInfo<'a>
impl<'a> PartialEq for EncryptedPrivateKeyInfo<'a>
Source§fn eq(&self, other: &EncryptedPrivateKeyInfo<'a>) -> bool
fn eq(&self, other: &EncryptedPrivateKeyInfo<'a>) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PemLabel for EncryptedPrivateKeyInfo<'_>
Available on crate feature pem only.
impl PemLabel for EncryptedPrivateKeyInfo<'_>
Available on crate feature
pem only.Source§impl<'a> TryFrom<&'a [u8]> for EncryptedPrivateKeyInfo<'a>
impl<'a> TryFrom<&'a [u8]> for EncryptedPrivateKeyInfo<'a>
Source§impl TryFrom<&EncryptedPrivateKeyInfo<'_>> for SecretDocument
Available on crate feature alloc only.
impl TryFrom<&EncryptedPrivateKeyInfo<'_>> for SecretDocument
Available on crate feature
alloc only.Source§fn try_from(
encrypted_private_key: &EncryptedPrivateKeyInfo<'_>,
) -> Result<SecretDocument>
fn try_from( encrypted_private_key: &EncryptedPrivateKeyInfo<'_>, ) -> Result<SecretDocument>
Performs the conversion.
Source§impl TryFrom<EncryptedPrivateKeyInfo<'_>> for SecretDocument
Available on crate feature alloc only.
impl TryFrom<EncryptedPrivateKeyInfo<'_>> for SecretDocument
Available on crate feature
alloc only.Source§fn try_from(
encrypted_private_key: EncryptedPrivateKeyInfo<'_>,
) -> Result<SecretDocument>
fn try_from( encrypted_private_key: EncryptedPrivateKeyInfo<'_>, ) -> Result<SecretDocument>
Performs the conversion.
impl<'a> Eq for EncryptedPrivateKeyInfo<'a>
impl<'a> Sequence<'a> for EncryptedPrivateKeyInfo<'a>
impl<'a> StructuralPartialEq for EncryptedPrivateKeyInfo<'a>
Auto Trait Implementations§
impl<'a> Freeze for EncryptedPrivateKeyInfo<'a>
impl<'a> RefUnwindSafe for EncryptedPrivateKeyInfo<'a>
impl<'a> Send for EncryptedPrivateKeyInfo<'a>
impl<'a> Sync for EncryptedPrivateKeyInfo<'a>
impl<'a> Unpin for EncryptedPrivateKeyInfo<'a>
impl<'a> UnwindSafe for EncryptedPrivateKeyInfo<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<'a, T> Decode<'a> for Twhere
T: DecodeValue<'a> + FixedTag,
impl<'a, T> Decode<'a> for Twhere
T: DecodeValue<'a> + FixedTag,
Source§impl<T> DecodePem for Twhere
T: DecodeOwned + PemLabel,
impl<T> DecodePem for Twhere
T: DecodeOwned + PemLabel,
Source§impl<T> Encode for Twhere
T: EncodeValue + Tagged,
impl<T> Encode for Twhere
T: EncodeValue + Tagged,
Source§fn encoded_len(&self) -> Result<Length, Error>
fn encoded_len(&self) -> Result<Length, Error>
Compute the length of this value in bytes when encoded as ASN.1 DER.
Source§fn encode(&self, writer: &mut impl Writer) -> Result<(), Error>
fn encode(&self, writer: &mut impl Writer) -> Result<(), Error>
Encode this value as ASN.1 DER using the provided Writer.
Source§fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
Encode this value to the provided byte slice, returning a sub-slice
containing the encoded message.