core::crypto::sha3
On this page
SHA-3 (FIPS 202): SHA3-256, SHA3-512 and the SHAKE128 / SHAKE256
extendable-output functions, all over Keccak-f[1600]. The types here
are the low-level form: one fixed function each, no algorithm chosen
at run time. HashAlgorithm::Sha3_256 / Sha3_512 with Digest,
Hmac and hkdf is the form chosen at run time.
Structs
Sha3_256Source
pub struct Sha3_256SHA3-256, fixed at compile time: 32-byte digests. The same function
as Digest::new(HashAlgorithm::Sha3_256).
The digest length in bytes.
An empty running hash.
The 32-byte SHA3-256 digest of
data, in one call.Feed
datainto the hash; callfinishfor the digest.The 32-byte digest of everything fed so far.
Trait implementations 1
impl Debug for Sha3_256
Sha3_512Source
pub struct Sha3_512SHA3-512, fixed at compile time: 64-byte digests. The same function
as Digest::new(HashAlgorithm::Sha3_512).
The digest length in bytes.
An empty running hash.
The 64-byte SHA3-512 digest of
data, in one call.Feed
datainto the hash; callfinishfor the digest.The 64-byte digest of everything fed so far.
Trait implementations 1
impl Debug for Sha3_512
Shake128Source
pub struct Shake128SHAKE128: update the input, then squeeze output in any pieces.
update after the first squeeze is not allowed.
An empty sponge.
Feed
datain; callsqueezefor output.The next
nbytes of output.
Trait implementations 1
impl Debug for Shake128
Shake256Source
pub struct Shake256SHAKE256, like Shake128.
An empty sponge.
Feed
datain; callsqueezefor output.The next
nbytes of output.
Trait implementations 1
impl Debug for Shake256