ringct: error out when hashToPoint* returns the point at infinity

Reported by QuarksLab.
This commit is contained in:
moneromooo-monero
2018-07-25 10:10:46 +01:00
parent d1591853bf
commit 7ed496cc78
2 changed files with 4 additions and 1 deletions
+1
View File
@@ -277,6 +277,7 @@ namespace rct {
for (j = 0; j < dsRows; j++) {
addKeys2(L, rv.ss[i][j], c_old, pk[i][j]);
hashToPoint(Hi, pk[i][j]);
CHECK_AND_ASSERT_MES(!(Hi == rct::identity()), false, "Data hashed to point at infinity");
addKeys3(R, rv.ss[i][j], Hi, c_old, Ip[j].k);
toHash[3 * j + 1] = pk[i][j];
toHash[3 * j + 2] = L;