18 releases (stable)

4.2.0 Apr 17, 2025
4.1.7 Apr 1, 2025
4.1.6 Mar 28, 2025
4.1.2 Feb 28, 2025
3.4.0 Nov 29, 2024

#7 in #succinct-sp1

Download history 1032/week @ 2025-01-09 1120/week @ 2025-01-16 684/week @ 2025-01-23 1128/week @ 2025-01-30 1102/week @ 2025-02-06 1124/week @ 2025-02-13 987/week @ 2025-02-20 1670/week @ 2025-02-27 1341/week @ 2025-03-06 1088/week @ 2025-03-13 1412/week @ 2025-03-20 1642/week @ 2025-03-27 740/week @ 2025-04-03 724/week @ 2025-04-10 813/week @ 2025-04-17 621/week @ 2025-04-24

3,223 downloads per month
Used in 4 crates (2 directly)

MIT/Apache

77KB
1.5K SLoC

SP1 Verifier

This crate provides verifiers for SP1 Groth16 and Plonk zero-knowledge proofs. These proofs are expected to be generated using the SP1 SDK.

Features

Groth16 and Plonk proof verification are supported in no-std environments. Verification in the SP1 zkVM context is patched, in order to make use of the bn254 precompiles.

Pre-generated verification keys

Verification keys for Groth16 and Plonk are stored in the bn254-vk directory. These vkeys are used to verify all SP1 proofs.

These vkeys are the same as those found locally in ~/.sp1/circuits/<circuit_name>/<version>/<circuit_name>_vk.bin, and should be automatically updated after every release.

Tests

Run tests with the following command:

cargo test --package sp1-verifier

These tests generate a groth16/plonk proof and verify it.

Acknowledgements

Adapted from @Bisht13's gnark-bn254-verifier crate.

Dependencies

~3.5–5.5MB
~127K SLoC