Consensys / anonymous-zether

A private payment system for Ethereum-based blockchains, with no trusted setup.
Other
295 stars 73 forks source link

update of CLn and CRn values during transfer #10

Closed panghalamit closed 5 years ago

panghalamit commented 5 years ago

https://github.com/jpmorganchase/anonymous-zether/blob/009f19b909a6f80387ae9c1c83112fc61341daa7/packages/anonymous.js/src/client.js#L254-L255

should be updated to

var CLn = result.map((simulated, i) => bn128.serialize(bn128.unserialize(simulated[0][0]).add(L[i])));
var CRn = result.map((simulated) => bn128.serialize(bn128.unserialize(simulated[0][1]).add(R)));
panghalamit commented 5 years ago

My bad, CL and CR each would be bytes32[2]. So closing this.