Skip to main content

Module sha3

Module sha3 

Source
Expand description

Keccak-f[1600] based SHAKE256 implementation (FIPS 202). SHA-3 / SHAKE high-level wrappers used by SLH-DSA (FIPS 205).

This module no longer carries its own copy of the Keccak permutation: it builds on top of the shared sponge core in crate::sha3. SLH-DSA only uses SHAKE256, exposed here through the Shake256 streaming context plus two one-shot helpers.

Structs§

KeccakState
Keccak sponge state for SHA-3 and SHAKE constructions.
Shake256
Incremental SHAKE256 context for multi-part absorb and squeeze.

Constants§

SHAKE256_RATE
SHAKE256 rate in bytes (1600-bit state minus 2·256-bit capacity, divided by 8).

Functions§

shake256
One-shot SHAKE256: absorb data and return out_len bytes of output. Allocates a Vec for the output.
shake256_into
One-shot SHAKE256: absorb data and squeeze into out.