Closed jpopxfile closed 5 years ago
The verification function checks that arguments are not nil:
func (pf *RangeProofAlice) Verify(pk *paillier.PublicKey, NTilde, h1, h2, c *big.Int) bool { if pf == nil || pk == nil || NTilde == nil || h1 == nil || h2 == nil || c == nil { return false } ...
However the proof creation does not perform any such checks (and might fail upon nil values when performing arithmetic operations):
func ProveRangeAlice(pk *paillier.PublicKey, c, NTilde, h1, h2, m, r *big.Int) *RangeProofAlice { q := tss.EC().Params().N q3 := new(big.Int).Mul(q, q) q3 = new(big.Int).Mul(q, q3) ...
We recommend to add nil checks for extra safety.
The verification function checks that arguments are not nil:
However the proof creation does not perform any such checks (and might fail upon nil values when performing arithmetic operations):
We recommend to add nil checks for extra safety.