Sha2BlockHasherSubairConfig

Trait Sha2BlockHasherSubairConfig 

Source
pub trait Sha2BlockHasherSubairConfig:
    Send
    + Sync
    + Clone {
    type Word: 'static + Shr<usize, Output = Self::Word> + Shl<usize, Output = Self::Word> + BitAnd<Output = Self::Word> + Not<Output = Self::Word> + BitXor<Output = Self::Word> + BitOr<Output = Self::Word> + RotateRight + WrappingAdd + PartialEq + From<u32> + TryInto<u32, Error: Debug> + Copy + Send + Sync;
Show 18 associated constants and 2 methods const VARIANT: Sha2Variant; const WORD_BITS: usize; const BLOCK_WORDS: usize; const ROWS_PER_BLOCK: usize; const ROUNDS_PER_ROW: usize; const ROUNDS_PER_BLOCK: usize; const HASH_WORDS: usize; const ROW_VAR_CNT: usize; const WORD_U16S: usize = _; const WORD_U8S: usize = _; const BLOCK_U8S: usize = _; const BLOCK_BITS: usize = _; const ROUND_ROWS: usize = _; const MESSAGE_ROWS: usize = _; const ROUNDS_PER_ROW_MINUS_ONE: usize = _; const SUBAIR_ROUND_WIDTH: usize = _; const SUBAIR_DIGEST_WIDTH: usize = _; const SUBAIR_WIDTH: usize = _; // Required methods fn get_k() -> &'static [Self::Word]; fn get_h() -> &'static [Self::Word];
}

Required Associated Constants§

Source

const VARIANT: Sha2Variant

Source

const WORD_BITS: usize

Number of bits in a SHA word

Source

const BLOCK_WORDS: usize

Number of words in a SHA block

Source

const ROWS_PER_BLOCK: usize

Number of rows per block

Source

const ROUNDS_PER_ROW: usize

Number of rounds per row. Must divide Self::ROUNDS_PER_BLOCK

Source

const ROUNDS_PER_BLOCK: usize

Number of rounds per block. Must be a multiple of Self::ROUNDS_PER_ROW

Source

const HASH_WORDS: usize

Number of words in a SHA hash

Source

const ROW_VAR_CNT: usize

Number of vars needed to encode the row index with Encoder

Provided Associated Constants§

Source

const WORD_U16S: usize = _

Number of 16-bit limbs in a SHA word

Source

const WORD_U8S: usize = _

Number of 8-bit limbs in a SHA word

Source

const BLOCK_U8S: usize = _

Number of cells in a SHA block

Source

const BLOCK_BITS: usize = _

Number of bits in a SHA block

Source

const ROUND_ROWS: usize = _

Number of rows used for the sha rounds

Source

const MESSAGE_ROWS: usize = _

Number of rows used for the message

Source

const ROUNDS_PER_ROW_MINUS_ONE: usize = _

Number of rounds per row minus one (needed for one of the column structs)

Source

const SUBAIR_ROUND_WIDTH: usize = _

Width of the Sha2RoundCols

Source

const SUBAIR_DIGEST_WIDTH: usize = _

Width of the Sha2DigestCols

Source

const SUBAIR_WIDTH: usize = _

Width of the Sha2BlockHasherCols

Required Associated Types§

Source

type Word: 'static + Shr<usize, Output = Self::Word> + Shl<usize, Output = Self::Word> + BitAnd<Output = Self::Word> + Not<Output = Self::Word> + BitXor<Output = Self::Word> + BitOr<Output = Self::Word> + RotateRight + WrappingAdd + PartialEq + From<u32> + TryInto<u32, Error: Debug> + Copy + Send + Sync

Required Methods§

Source

fn get_k() -> &'static [Self::Word]

We also store the SHA constants K and H

Source

fn get_h() -> &'static [Self::Word]

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§

Source§

impl Sha2BlockHasherSubairConfig for Sha256Config

Source§

impl Sha2BlockHasherSubairConfig for Sha384Config

Source§

const VARIANT: Sha2Variant = Sha2Variant::Sha384

Source§

const WORD_BITS: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::WORD_BITS

Source§

const BLOCK_WORDS: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::BLOCK_WORDS

Source§

const ROWS_PER_BLOCK: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::ROWS_PER_BLOCK

Source§

const ROUNDS_PER_ROW: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::ROUNDS_PER_ROW

Source§

const ROUNDS_PER_BLOCK: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::ROUNDS_PER_BLOCK

Source§

const HASH_WORDS: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::HASH_WORDS

Source§

const ROW_VAR_CNT: usize = <Sha512Config as Sha2BlockHasherSubairConfig>::ROW_VAR_CNT

Source§

type Word = <Sha512Config as Sha2BlockHasherSubairConfig>::Word

Source§

impl Sha2BlockHasherSubairConfig for Sha512Config