Skip to content

Commit 3762247

Browse files
committed
bug fix
Signed-off-by: Angelo De Caro <adc@zurich.ibm.com>
1 parent ceb1ce9 commit 3762247

File tree

1 file changed

+5
-4
lines changed
  • token/core/zkatdlog/nogh/v1/crypto/rp

1 file changed

+5
-4
lines changed

token/core/zkatdlog/nogh/v1/crypto/rp/ipa.go

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -298,10 +298,11 @@ func (v *ipaVerifier) Verify(proof *IPA) error {
298298

299299
X := v.Q.Mul(x)
300300

301-
var leftGen []*mathlib.G1
302-
var rightGen []*mathlib.G1
303-
leftGen = v.LeftGenerators
304-
rightGen = v.RightGenerators
301+
leftGen := make([]*mathlib.G1, len(v.LeftGenerators))
302+
copy(leftGen, v.LeftGenerators)
303+
rightGen := make([]*mathlib.G1, len(v.RightGenerators))
304+
copy(rightGen, v.RightGenerators)
305+
305306
for i := range v.NumberOfRounds {
306307
// check well-formedness
307308
if proof.L[i] == nil || proof.R[i] == nil {

0 commit comments

Comments
 (0)