pub trait ExpandMsg<'a> {
    type Expander: Expander + Sized;

    // Required method
    fn expand_message(
        msgs: &[&[u8]],
        dsts: &'a [&'a [u8]],
        len_in_bytes: usize
    ) -> Result<Self::Expander, Error>;
}
Expand description

Trait for types implementing expand_message interface for hash_to_field.

Errors

See implementors of ExpandMsg for errors.

Required Associated Types§

type Expander: Expander + Sized

Type holding data for the Expander.

Required Methods§

fn expand_message( msgs: &[&[u8]], dsts: &'a [&'a [u8]], len_in_bytes: usize ) -> Result<Self::Expander, Error>

Expands msg to the required number of bytes.

Returns an expander that can be used to call read until enough bytes have been consumed

Implementors§

§

impl<'a, HashT> ExpandMsg<'a> for ExpandMsgXmd<HashT>where HashT: BlockSizeUser + Default + FixedOutput + HashMarker, <HashT as OutputSizeUser>::OutputSize: IsLess<UInt<UInt<UInt<UInt<UInt<UInt<UInt<UInt<UInt<UTerm, B1>, B0>, B0>, B0>, B0>, B0>, B0>, B0>, B0>> + IsLessOrEqual<<HashT as BlockSizeUser>::BlockSize>,

ExpandMsgXmd implements expand_message_xmd for the ExpandMsg trait

§

type Expander = ExpanderXmd<'a, HashT>

§

impl<'a, HashT> ExpandMsg<'a> for ExpandMsgXof<HashT>where HashT: Default + ExtendableOutput + Update,

ExpandMsgXof implements expand_message_xof for the ExpandMsg trait

§

type Expander = ExpandMsgXof<HashT>