Crate ark_sponge
source ·Expand description
A crate for the cryptographic sponge trait.
Modules
Infrastructure for the constraints counterparts.
The sponge for Poseidon
Macros
Individually absorbs each element in a comma-separated list of absorbables into a sponge.
Format is
absorb!(s, a_0, a_1, ..., a_n)
, where s
is a mutable reference to a sponge
and each a_i
implements Absorb
.Individually absorbs each element in a comma-separated list of [
Absorbable
]s into a sponge.
Format is absorb!(s, a_0, a_1, ..., a_n)
, where s
is a mutable reference to a sponge
and each a_i
implements AbsorbableVar
.Quickly convert a list of different
Absorb
s into sponge bytes.Quickly convert a list of different
Absorb
s into sponge field elements.Quickly convert a list of different [
Absorbable
]s into sponge field elements.Enums
The mode structure for duplex sponges
An enum for specifying the output field element size.
Traits
An interface for objects that can be absorbed by a
CryptographicSponge
.An extension to
Absorb
that is specific to items with variable length, such as a list.The interface for a cryptographic sponge.
A sponge can
absorb
or take in inputs and later squeeze
or output bytes or field elements.
The outputs are dependent on previous absorb
and squeeze
calls.The interface for field-based cryptographic sponge.
CF
is the native field used by the cryptographic sponge implementation.An extension for the interface of a cryptographic sponge.
In addition to operations defined in
CryptographicSponge
, SpongeExt
can convert itself to
a state, and instantiate itself from state.