pub struct SecretKey768 { /* private fields */ }Expand description
ML-KEM-768 decapsulation key (secret key).
Implementations§
Source§impl SecretKey768
impl SecretKey768
pub fn from_bytes(bytes: &[u8; 2400]) -> Self
pub fn to_bytes(&self) -> [u8; 2400]
pub fn generate() -> (Self, PublicKey768)
pub fn decapsulate( &self, ciphertext: &[u8; 1088], ) -> Result<[u8; 32], MlKemError>
pub fn public_key(&self) -> PublicKey768
Trait Implementations§
Source§impl Clone for SecretKey768
impl Clone for SecretKey768
Source§fn clone(&self) -> SecretKey768
fn clone(&self) -> SecretKey768
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SecretKey768
impl Debug for SecretKey768
Source§impl Drop for SecretKey768
impl Drop for SecretKey768
impl Eq for SecretKey768
Source§impl PartialEq for SecretKey768
impl PartialEq for SecretKey768
Source§fn eq(&self, other: &SecretKey768) -> bool
fn eq(&self, other: &SecretKey768) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for SecretKey768
Source§impl TryFrom<&[u8]> for SecretKey768
impl TryFrom<&[u8]> for SecretKey768
Auto Trait Implementations§
impl Freeze for SecretKey768
impl RefUnwindSafe for SecretKey768
impl Send for SecretKey768
impl Sync for SecretKey768
impl Unpin for SecretKey768
impl UnsafeUnpin for SecretKey768
impl UnwindSafe for SecretKey768
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