Auto merge of #1126 - ebfull:more-libsnark-changes, r=ebfull
Remove more from libsnark, and fix potential remote-DoS. See https://github.com/zcash/libsnark/pull/1 as well. [`59adbef`](59adbefcc8) removes a remote-DoS that can occur if proofs are not well-formed. [`e3779f9`](e3779f9049) removes more files that we do not need from libsnark. [`11242d8`](11242d8afe) replaces assertions that could be triggered by our verifier with exceptions. Here in Zcash, we catch all exceptions from the verifier and return false. Closes #459, Closes #69
This commit is contained in:
@@ -157,7 +157,11 @@ public:
|
||||
vpub_new
|
||||
);
|
||||
|
||||
return r1cs_ppzksnark_verifier_strong_IC<ppzksnark_ppT>(*vk, witness, r1cs_proof);
|
||||
try {
|
||||
return r1cs_ppzksnark_verifier_strong_IC<ppzksnark_ppT>(*vk, witness, r1cs_proof);
|
||||
} catch (...) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
boost::array<unsigned char, ZKSNARK_PROOF_SIZE> prove(
|
||||
|
||||
Reference in New Issue
Block a user