Skip to content

Commit

Permalink
hack: pad bulletproof chals when serializing proof
Browse files Browse the repository at this point in the history
  • Loading branch information
mitschabaude committed May 24, 2022
1 parent acad0a2 commit a879d80
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions src/lib/pickles/proof.ml
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,24 @@ module Make (W : Nat.Intf) (MLMB : Nat.Intf) = struct
(Vector.length t.statement.pass_through.challenge_polynomial_commitments)
W.n
in
(* pad me_only.old_bulletproof_challenges with dummies ... is this breaking anything??? *)
let bp_chals =
Vector.to_list t.statement.proof_state.me_only.old_bulletproof_challenges
in
let old_bulletproof_challenges =
Vector.init MLMB.n ~f:(fun i ->
Option.value (List.nth bp_chals i) ~default:Dummy.Ipa.Wrap.challenges )
in
{ t with
statement =
{ t.statement with
pass_through =
{ proof_state =
{ t.statement.proof_state with
me_only =
{ t.statement.proof_state.me_only with
old_bulletproof_challenges
}
}
; pass_through =
{ t.statement.pass_through with
challenge_polynomial_commitments =
At_most.of_vector
Expand Down

0 comments on commit a879d80

Please sign in to comment.