Struct diem_crypto::hkdf::Hkdf [−][src]
pub struct Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>, { /* fields omitted */ }
Expand description
Structure representing the HKDF, capable of HKDF-Extract and HKDF-Expand operations, as defined in RFC 5869.
Implementations
impl<D> Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8> + Clone,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
impl<D> Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8> + Clone,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
The RFC5869 HKDF-Extract operation.
The RFC5869 HKDF-Expand operation.
HKDF Extract then Expand operation as a single step.
CAUTION: This is not recommended because it does not take an ikm (seed) as an input and
thus, it is not fully compliant with the HKDF RFC (which always expects a non-zero ikm).
Please use extract_then_expand
instead, unless you know what you are doing.
This api is currently required by the Noise protocol HKDF specs.
HKDF Extract then Expand operation as a single step, but without an ikm input.
Trait Implementations
impl<D: Clone> Clone for Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
impl<D: Clone> Clone for Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
impl<D: Debug> Debug for Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
impl<D: Debug> Debug for Hkdf<D> where
D: Update + BlockInput + FixedOutput + Reset + Default + Clone,
D::BlockSize: ArrayLength<u8>,
D::OutputSize: ArrayLength<u8>,
D::OutputSize: IsGreaterOrEqual<U32, Output = True>,
Auto Trait Implementations
impl<D> RefUnwindSafe for Hkdf<D> where
D: RefUnwindSafe,
impl<D> UnwindSafe for Hkdf<D> where
D: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more