Documentation ¶
Overview ¶
Package curl implements the BCT Curl hashing function computing multiple Curl hashes in parallel.
Index ¶
Constants ¶
View Source
const ( // StateSize is the size of the Curl hash function. StateSize = consts.HashTrinarySize * 3 // NumRounds is the number of rounds in a Curl transform. NumRounds = 81 )
View Source
const MaxBatchSize = bits.UintSize
MaxBatchSize is the maximum number of Curl hashes that can be computed in one batch.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Curl ¶
type Curl struct {
// contains filtered or unexported fields
}
Curl is the BCT version of the Curl hashing function.
func (*Curl) Absorb ¶
Absorb fills the states of the sponge with src; each element of src must have the length tritsCount. The value tritsCount has to be a multiple of HashTrinarySize.
type SpongeDirection ¶
type SpongeDirection int
SpongeDirection indicates the direction trits are flowing through the sponge.
const ( // SpongeAbsorbing indicates that the sponge is absorbing input. SpongeAbsorbing SpongeDirection = iota // SpongeSqueezing indicates that the sponge is being squeezed. SpongeSqueezing )
Click to show internal directories.
Click to hide internal directories.