Skip to content

Commit

Permalink
Add fix for RELIC parsing invalid inputs.
Browse files Browse the repository at this point in the history
  • Loading branch information
Fuzzbawls committed Apr 15, 2023
1 parent 188967e commit adb7110
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/elements.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ G1Element G1Element::FromBytes(const Bytes& bytes)
}
}
g1_read_bin(ele.p, buffer, G1Element::SIZE + 1);
BLS::CheckRelicErrors();
ele.CheckValid();
return ele;
}
Expand Down Expand Up @@ -241,6 +242,7 @@ G2Element G2Element::FromBytes(const Bytes& bytes)
}

g2_read_bin(ele.q, buffer, G2Element::SIZE + 1);
BLS::CheckRelicErrors();
ele.CheckValid();
return ele;
}
Expand Down

0 comments on commit adb7110

Please sign in to comment.