Trait DeriveKeyXof

Source
pub trait DeriveKeyXof: ExtendableOutputFunction {
    // Required method
    fn for_derive_key(context: &[u8]) -> Result<Self>
       where Self: Sized;

    // Provided method
    fn derive_key(context: &[u8], data: &[u8], len: usize) -> Result<Vec<u8>>
       where Self: Sized { ... }
}
Expand description

Helper trait for XOFs that support key derivation mode

Required Methods§

Source

fn for_derive_key(context: &[u8]) -> Result<Self>
where Self: Sized,

Creates a new XOF instance for key derivation

Provided Methods§

Source

fn derive_key(context: &[u8], data: &[u8], len: usize) -> Result<Vec<u8>>
where Self: Sized,

Derives key material in a single call

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§