Skip to content

Commit 5c0be19

Browse files
committed
Merge #21: Add fix for RELIC parsing invalid inputs.
adb7110 Add fix for RELIC parsing invalid inputs. (Fuzzbawls) Pull request description: This patch handles RELIC errors when invalid inputs are provided. Ref: Chia-Network#249 Extracted From: #12 ACKs for top commit: panleone: utACK adb7110 Liquid369: ACK adb7110 Tree-SHA512: 8e9bbf2c4444055c63b17ee9311571ed74ca5c527cc48c49e374c9dd404423383426f0b2bc0aeccf6995d9bd40deb8538f8d7d7429aef4e4d0d9cc6372c9174a
2 parents 1446804 + adb7110 commit 5c0be19

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/elements.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ G1Element G1Element::FromBytes(const Bytes& bytes)
5858
}
5959
}
6060
g1_read_bin(ele.p, buffer, G1Element::SIZE + 1);
61+
BLS::CheckRelicErrors();
6162
ele.CheckValid();
6263
return ele;
6364
}
@@ -241,6 +242,7 @@ G2Element G2Element::FromBytes(const Bytes& bytes)
241242
}
242243

243244
g2_read_bin(ele.q, buffer, G2Element::SIZE + 1);
245+
BLS::CheckRelicErrors();
244246
ele.CheckValid();
245247
return ele;
246248
}

0 commit comments

Comments
 (0)