diff --git a/Cargo.toml b/Cargo.toml index f1c0f90..71e2a89 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "ark-linear-sumcheck" +name = "ark-sumcheck" version = "0.4.0" authors = [ "Tom Shen ", @@ -8,7 +8,7 @@ authors = [ description = "A library for efficient sumcheck protocols" homepage = "https://arkworks.rs" repository = "https://github.com/arkworks-rs/sumcheck/" -keywords = ["cryptography", "finite-fields", "polynomials", "sumcheck"] +keywords = ["cryptography", "finite-fields", "polynomials", "sumcheck", "gkr"] categories = ["cryptography"] include = ["Cargo.toml", "src", "README.md", "LICENSE-APACHE", "LICENSE-MIT"] license = "MIT/Apache-2.0" diff --git a/src/ml_sumcheck/mod.rs b/src/ml_sumcheck/mod.rs index 52c8ad0..86180ca 100644 --- a/src/ml_sumcheck/mod.rs +++ b/src/ml_sumcheck/mod.rs @@ -62,6 +62,9 @@ impl MLSumcheck { prover_msgs.push(prover_msg); verifier_msg = Some(IPForMLSumcheck::sample_round(fs_rng)); } + prover_state + .randomness + .push(verifier_msg.unwrap().randomness); Ok((prover_msgs, prover_state)) } diff --git a/src/ml_sumcheck/test.rs b/src/ml_sumcheck/test.rs index 6d92755..ae06801 100644 --- a/src/ml_sumcheck/test.rs +++ b/src/ml_sumcheck/test.rs @@ -107,7 +107,7 @@ fn test_polynomial_as_subprotocol( let (poly, asserted_sum) = random_list_of_products::(nv, num_multiplicands_range, num_products, &mut rng); let poly_info = poly.info(); - let (proof, _prover_state) = + let (proof, prover_state) = MLSumcheck::prove_as_subprotocol(prover_rng, &poly).expect("fail to prove"); let subclaim = MLSumcheck::verify_as_subprotocol(verifier_rng, &poly_info, asserted_sum, &proof) @@ -116,6 +116,7 @@ fn test_polynomial_as_subprotocol( poly.evaluate(&subclaim.point) == subclaim.expected_evaluation, "wrong subclaim" ); + assert_eq!(prover_state.randomness, subclaim.point); } #[test]