pub struct RustCryptoX448Key(/* private fields */);Expand description
Opaque RustCrypto X448 private key, zeroized on drop without secret export.
Implementations§
Source§impl RustCryptoX448Key
impl RustCryptoX448Key
Sourcepub fn from_bytes(bytes: [u8; 56]) -> Self
pub fn from_bytes(bytes: [u8; 56]) -> Self
Import a 56-byte scalar; clamping follows RFC 7748 section 5.
Sourcepub fn from_pkcs8_der(bytes: &[u8]) -> Result<Self, ProviderError>
pub fn from_pkcs8_der(bytes: &[u8]) -> Result<Self, ProviderError>
Import RFC 8410 PKCS#8, validating any included public-key identity. DER is borrowed; only the fixed-width scalar enters the zeroizing key.
Sourcepub fn public_key(&self) -> [u8; 56]
pub fn public_key(&self) -> [u8; 56]
Return the RFC 7748 section 5 little-endian public u-coordinate.
Trait Implementations§
Source§impl Debug for RustCryptoX448Key
impl Debug for RustCryptoX448Key
Source§impl KeyAgreementKey for RustCryptoX448Key
impl KeyAgreementKey for RustCryptoX448Key
Source§fn agree(
&self,
parameters: &KeyAgreementParameters<'_>,
) -> Result<Vec<u8>, ProviderError>
fn agree( &self, parameters: &KeyAgreementParameters<'_>, ) -> Result<Vec<u8>, ProviderError>
Derive the raw shared secret for the supplied peer and parameters.
Source§fn dh_domain_bits(&self) -> Option<(usize, usize)>
fn dh_domain_bits(&self) -> Option<(usize, usize)>
Public modulus/subgroup bit widths for finite-field DH. Operations use
these to recheck key strength under their own policy; no secret is exported.
Source§fn provider_binding(&self) -> Option<&ProviderBinding>
fn provider_binding(&self) -> Option<&ProviderBinding>
External execution domain, when the private key resides outside this process.
Auto Trait Implementations§
impl Freeze for RustCryptoX448Key
impl RefUnwindSafe for RustCryptoX448Key
impl Send for RustCryptoX448Key
impl Sync for RustCryptoX448Key
impl Unpin for RustCryptoX448Key
impl UnsafeUnpin for RustCryptoX448Key
impl UnwindSafe for RustCryptoX448Key
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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