From f65597be3bef2cc56610a16f846ebe32f3a0ee41 Mon Sep 17 00:00:00 2001 From: Nuke Date: Tue, 1 Apr 2025 10:04:09 -0600 Subject: [PATCH 1/2] test data --- common/src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/common/src/lib.rs b/common/src/lib.rs index 94f72e3..798de40 100644 --- a/common/src/lib.rs +++ b/common/src/lib.rs @@ -1,2 +1,3 @@ pub const INPUT_BYTES: &[u8] = include_bytes!("../../static/proof_input_example.bin"); +// pub const INPUT_BYTES: &[u8] = &[42;10_000]; pub const INPUT_BYTES_LENGTH: usize = INPUT_BYTES.len(); From 54bd2b5f88c894ef5fddf18f342bb845e9c2f960 Mon Sep 17 00:00:00 2001 From: Nuke Date: Tue, 1 Apr 2025 10:04:40 -0600 Subject: [PATCH 2/2] groth16 option --- host/src/main.rs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/host/src/main.rs b/host/src/main.rs index a59c700..25c42ba 100644 --- a/host/src/main.rs +++ b/host/src/main.rs @@ -5,7 +5,7 @@ use chacha20::ChaCha20; // The ELF is used for proving and the ID is used for verification. use methods::GUEST_ENCRYPT_ELF; use risc0_zkvm::sha::rust_crypto::{Digest, Sha256}; -use risc0_zkvm::{default_prover, ExecutorEnv}; +use risc0_zkvm::{default_prover, ExecutorEnv, ProverOpts, VerifierContext}; use common::INPUT_BYTES; @@ -36,7 +36,14 @@ fn main() { // Proof information by proving the specified ELF binary. // This struct contains the receipt along with statistics about execution of the guest - let prove_info = prover.prove(env, GUEST_ENCRYPT_ELF).unwrap(); + let prove_info = prover + .prove_with_ctx( + env, + &VerifierContext::default(), + GUEST_ENCRYPT_ELF, + &ProverOpts::groth16(), + ) + .unwrap(); // extract the receipt. let receipt = prove_info.receipt;