bulletproofs: scale points by 8 to ensure subgroup validity

This commit is contained in:
moneromooo-monero 2018-08-06 11:05:20 +00:00
parent c83012c476
commit 044dff5a30
No known key found for this signature in database
GPG key ID: 686F07454D6CEFC3
4 changed files with 33 additions and 19 deletions

View file

@ -169,7 +169,7 @@ namespace cryptonote
CHECK_AND_ASSERT_MES(n_amounts == rv.outPk.size(), false, "Internal error filling out V");
rv.p.bulletproofs[0].V.resize(n_amounts);
for (size_t i = 0; i < n_amounts; ++i)
rv.p.bulletproofs[0].V[i] = rv.outPk[i].mask;
rv.p.bulletproofs[0].V[i] = rct::scalarmultKey(rv.outPk[i].mask, rct::INV_EIGHT);
}
}
}