We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#[test] fn groth16_proof() -> Result<()> { let cfg = CircomConfig::<Bn254>::new( "hash.wasm", "hash.r1cs", )?; let mut builder = CircomBuilder::new(cfg); builder.push_input("a", 3); builder.push_input("b", 11); // create an empty instance for setting it up let circom = builder.setup(); let mut rng = thread_rng(); let params = GrothBn::generate_random_parameters_with_reduction(circom, &mut rng)?; let circom = builder.build()?; let inputs = circom.get_public_inputs().unwrap(); let proof = GrothBn::prove(¶ms, circom, &mut rng)?; let pvk = GrothBn::process_vk(¶ms.vk).unwrap(); let verified = GrothBn::verify_with_processed_vk(&pvk, &inputs, &proof)?; assert!(verified); Ok(()) }
The text was updated successfully, but these errors were encountered:
Do you have the "hash.wasm", "hash.r1cs" files at hand?
Sorry, something went wrong.
No branches or pull requests
The text was updated successfully, but these errors were encountered: