Skip to content

fix: bind EmbedMachine::verify to embed VK#102

Open
eason1981 wants to merge 1 commit into
mainfrom
fix-embed-verify
Open

fix: bind EmbedMachine::verify to embed VK#102
eason1981 wants to merge 1 commit into
mainfrom
fix-embed-verify

Conversation

@eason1981

Copy link
Copy Markdown
Contributor

Summary

EmbedMachine::verify took the VK directly from the proof (proof.vks()[0]) and passed it to verify_ensemble without checking it against the embed circuit VK. A malicious prover could prove an arbitrary recursion program, package its VK into MetaProof, and have it accepted.

Fix: store the embed VK in a OnceLock during prove, and use it in verify_ensemble instead of the proof-supplied VK.

Store the embed VK in an OnceLock during prove and use it directly in
verify_ensemble, preventing a malicious prover from substituting an
arbitrary recursion program VK and bypassing the embed circuit check.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant