pub trait Hasher {
    fn sha256<'life0, 'life1, 'async_trait>(
        &'life0 self,
        data: &'life1 [u8]
    ) -> Pin<Box<dyn Future<Output = Result<[u8; 32]>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        Self: 'async_trait
; fn hkdf_sha256<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        salt: &'life1 KeyId,
        info: &'life2 [u8],
        ikm: Option<&'life3 KeyId>,
        output_attributes: SmallBuffer<SecretAttributes>
    ) -> Pin<Box<dyn Future<Output = Result<SmallBuffer<KeyId>>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        'life2: 'async_trait,
        'life3: 'async_trait,
        Self: 'async_trait
; }
Expand description

A trait for hashing input data into a fixed length output.

Required Methods

Compute the SHA-256 digest given input data.

Derive multiple output [Secret]s with given attributes using the HKDF-SHA256 given the specified salt, info and input key material.

Implementors