ingonyama-zk / icicle

A hardware acceleration library for compute intensive cryptography :ice_cube:
https://dev.ingonyama.com/icicle/overview
MIT License
329 stars 97 forks source link

Groth16 test with verification #451

Closed DmytroTym closed 6 months ago

DmytroTym commented 6 months ago

This PR adds a "dummy verifier" to Groth16 and a test which swaps G2 for the scalar field. This allows checking correctness without pairings. One change to the prover that was needed for everything to work is zero padding to the power of two without which verifier fails. One small fix also added which corrects Projective::from_affine function for zero input.