pub struct AsconCxof128 { /* private fields */ }Expand description
Ascon-CXOF128 customizable extensible-output function (NIST SP 800-232 §5.3).
Extends Ascon-XOF128 with a customization string Z (up to 256 bytes).
The customization is absorbed before the message, so new_with_customization(b"")
produces different output than AsconXof128 on the same input.
Implements the Xof trait.
§Panics
Panics if the customization string exceeds 256 bytes.
§Incremental API
ⓘ
use crypto::{ascon::AsconCxof128, Xof};
let mut cxof = AsconCxof128::new_with_customization(b"my-app-v1");
cxof.absorb(b"hello world");
let mut out = [0u8; 32];
cxof.squeeze(&mut out);Implementations§
Source§impl AsconCxof128
impl AsconCxof128
Trait Implementations§
Source§impl Clone for AsconCxof128
impl Clone for AsconCxof128
Source§fn clone(&self) -> AsconCxof128
fn clone(&self) -> AsconCxof128
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 Drop for AsconCxof128
impl Drop for AsconCxof128
Source§impl Xof for AsconCxof128
impl Xof for AsconCxof128
Auto Trait Implementations§
impl Freeze for AsconCxof128
impl RefUnwindSafe for AsconCxof128
impl Send for AsconCxof128
impl Sync for AsconCxof128
impl Unpin for AsconCxof128
impl UnsafeUnpin for AsconCxof128
impl UnwindSafe for AsconCxof128
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