pub struct XWing768Algo;Expand description
X-Wing ML-KEM-768 hybrid KEM adapter.
Implementations§
Source§impl XWing768Algo
impl XWing768Algo
Sourcepub fn generate_keypair() -> Result<(Vec<u8>, Zeroizing<Vec<u8>>), AlgorithmError>
pub fn generate_keypair() -> Result<(Vec<u8>, Zeroizing<Vec<u8>>), AlgorithmError>
Generate an X-Wing-768 keypair.
Sourcepub fn encapsulate(
public_key: &[u8],
) -> Result<(Zeroizing<Vec<u8>>, Vec<u8>), AlgorithmError>
pub fn encapsulate( public_key: &[u8], ) -> Result<(Zeroizing<Vec<u8>>, Vec<u8>), AlgorithmError>
Encapsulate using the public key.
Sourcepub fn decapsulate(
ciphertext: &[u8],
secret_key: &[u8],
) -> Result<Zeroizing<Vec<u8>>, AlgorithmError>
pub fn decapsulate( ciphertext: &[u8], secret_key: &[u8], ) -> Result<Zeroizing<Vec<u8>>, AlgorithmError>
Decapsulate using the secret key.
Auto Trait Implementations§
impl Freeze for XWing768Algo
impl RefUnwindSafe for XWing768Algo
impl Send for XWing768Algo
impl Sync for XWing768Algo
impl Unpin for XWing768Algo
impl UnsafeUnpin for XWing768Algo
impl UnwindSafe for XWing768Algo
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