Documentation
¶
Index ¶
- Constants
- Variables
- func Hash(inpBI []*big.Int) (*big.Int, error)
- func HashBytes(msg []byte) (*big.Int, error)
- func HashBytesX(msg []byte, frameSize int) (*big.Int, error)
- func HashWithState(inpBI []*big.Int, initState *big.Int) (*big.Int, error)
- func New(frameSize int) (hash.Hash, error)
- func SpongeHash(inputs []*big.Int) (*big.Int, error)
- func SpongeHashX(inputs []*big.Int, frameSize int) (*big.Int, error)
- func Sum(b []byte) []byte
Constants ¶
View Source
const NROUNDSF = 8
NROUNDSF constant from Poseidon paper
Variables ¶
View Source
var NROUNDSP = []int{56, 57, 56, 60, 60, 63, 64, 63, 60, 66, 60, 65, 70, 60, 64, 68}
NROUNDSP constant from Poseidon paper
Functions ¶
func HashBytesX ¶
HashBytesX returns a sponge hash of a msg byte slice split into blocks of 31 bytes
func HashWithState ¶
HashWithState computes the Poseidon hash for the given inputs and initState
func SpongeHash ¶
SpongeHash returns a sponge hash of inputs (using Poseidon with frame size of 16 inputs)
func SpongeHashX ¶
SpongeHashX returns a sponge hash of inputs using Poseidon with configurable frame size
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.