Module sha

Module sha 

Source
Expand description

Simple SHA-256 wrappers.

Re-exports§

pub use crate::core::hash::sha::cpu::Impl;

Modules§

cpu
Simple wrappers for a CPU-based SHA-256 implementation.
guest
Functions for computing SHA-256 hashes.
rust_crypto
Rust Crypto wrappers for the RISC0 Sha256 trait.
testutil

Structs§

Block
Input block to the SHA-256 hashing algorithm. SHA-256 consumes blocks in 512-bit (64-byte) chunks in a Merkle–Damgård construction.
Sha256HashSuite
Make a hash suite from a Sha256 trait

Constants§

BLOCK_BYTES
Size of the Block representation in bytes.
BLOCK_WORDS
The number of words in the representation of a Block.
SHA256_INIT
Standard SHA-256 initialization vector.
WORD_SIZE
Size of a zkVM machine word in bytes. 4 bytes (i.e. 32 bits) as the zkVM is an implementation of the rv32im ISA.

Traits§

Sha256
An implementation of the SHA-256 hashing algorithm of FIPS 180-4.