Adds additional logic to the binary::verify function to check the proof index against the length of the proof set. The proof index tells us the minimum size of the tree's leaf set. The provided proof set along the leaf-root path must be compatible with the calculated path length.
Adds proptests for binary::verify to ensure correctness of algorithm
Checklist
[x] Breaking changes are clearly marked as such in the PR description and changelog
[x] New behavior is reflected in tests
[x] If performance characteristic of an instruction change, update gas costs as well or make a follow-up PR for that
[x] The specification matches the implemented behavior (link update PR if changes are needed)
Before requesting review
[x] I have reviewed the code myself
[x] I have created follow-up issues caused by this PR and linked them here
Closes: https://github.com/FuelLabs/fuel-vm/issues/716
This PR:
binary::verify
function to check the proof index against the length of the proof set. The proof index tells us the minimum size of the tree's leaf set. The provided proof set along the leaf-root path must be compatible with the calculated path length.binary::verify
to ensure correctness of algorithmChecklist
Before requesting review
After merging, notify other teams
[Add or remove entries as needed]