verify_gnark_proof can cause panic if the proof is wrong #1830
Labels
bug
Something isn't working
good first issue
Good for newcomers
rust
Pull requests that update Rust code
sdk
Issues or PRs relating to the SP1 SDK
Component
sp1-sdk
Have you ensured that all of these are up to date?
What version of SP1 SDK are you on?
No response
What version of the cargo prove CLI are you on?
No response
Operating System
None
Describe the bug
The
verify_gnark_proof
function can cause a panic if the proof is wrong as it usesunwraps
.The function already returns a
Result<(), Groth16Error>
and in case of wrong proof it should return an error and not panic.All
.unwrap()
calls should be removed.The text was updated successfully, but these errors were encountered: