microsoft / Spartan

Spartan: High-speed zkSNARKs without trusted setup
MIT License
691 stars 121 forks source link

dense_mlpoly.rs: Fix manipulation of evaluation vector Z by bound functions #73

Closed asn-d6 closed 1 month ago

asn-d6 commented 1 month ago

The bound functions were folding the Z vector on itself but were not actually truncating it (even though they were changing self.len).

Hence, if you called a bound function and then evaluate() it would assert because evaluate() checks the size of the Z vector.

(PR copied from https://github.com/nexus-xyz/nexus-zkvm/pull/283)