arkworks-rs / marlin

A Rust library for the Marlin preprocessing zkSNARK
Apache License 2.0
315 stars 85 forks source link

Why test actually failed inside the `prove_and_verify_with_tall_matrix_big`? #9

Closed 3for closed 4 years ago

3for commented 4 years ago

I run the cmd

cargo test prove_and_verify_with_tall_matrix_big -- --nocapture

and get the print info as below:

running 1 test
Called index
Called prover
Called verifier

Should not verify (i.e. verifier messages should print below):
Inner sumcheck test failed
AHP decision predicate not satisfied
PC::Check failed
Called index
Called prover
Called verifier

Should not verify (i.e. verifier messages should print below):
Inner sumcheck test failed
AHP decision predicate not satisfied
PC::Check failed
Called index
Called prover
Called verifier 
...........
Pratyush commented 4 years ago

The test has two checks: it verifies a correct proof against a correct public input, and verifies a correct proof against an incorrect public input. The latter check should fail, which gives the output that you see :)