iden3 / go-iden3-crypto

Go implementation of some cryptographic primitives (that fit inside the SNARK field) and compatible with circomlib
Apache License 2.0
117 stars 38 forks source link

[Poseidon] Add support for setting the initial state #61

Closed mdehoog closed 7 months ago

mdehoog commented 7 months ago

The initial state is an input in the circom circuit: https://github.com/iden3/circomlib/blob/cff5ab6288b55ef23602221694a6a38a0239dcc0/circuits/poseidon.circom#L69

This PR adds this support to the Golang poseidon hasher, retaining backwards compatibility.

mdehoog commented 7 months ago

Duplicate of #60