AleoNet / snarkVM

A Virtual Machine for Zero-Knowledge Executions
https://snarkvm.org
Apache License 2.0
1.06k stars 1.49k forks source link

[Fix] Add robustness to solution verification #2520

Closed raychu86 closed 2 months ago

raychu86 commented 2 months ago

Motivation

This PR updates block production to correctly address malicious solutions. This fix overwrites the solution target with value calculated during solution verification. So even if a malicious solution is injected by a malicious validator, honest validators will always process them and safely convert them to honest solutions.

CI run is here.

Test Plan

Tests have been added to ensure that malicious solutions are handled correctly.

raychu86 commented 2 months ago

Closing this PR for now due to unifying the fix in https://github.com/AleoNet/snarkVM/pull/2521.