Crate liminal_ark_pnbr_poseidon_paramgen

Crate liminal_ark_pnbr_poseidon_paramgen 

Source
Expand description

Module for generating parameters for the Poseidon SNARK-friendly hash function.

This crate will, given a choice of:

  • M, the desired security level (in bits),
  • t, the width of the desired hash function, e.g. $t=3$ corresponds to 2-to-1 hash.
  • p, the prime modulus,
  • allow_inverse, whether or not to allow an inverse alpha for the Sbox layer.

generate the best choice of parameters, for both the unoptimized version of Poseidon specified in the Poseidon paper, as well as the optimizations described in Appendix B.

Modules§

poseidon_build
For generating parameters at build time.

Functions§

generate
Generate a Poseidon instance mapped over Fp given a choice of: