Skip to content

Commit

Permalink
Merge pull request #60 from stevieraykatz/Fix_ecAff_isOnCurve
Browse files Browse the repository at this point in the history
Fix operand in ecAff_isOnCurve
  • Loading branch information
rdubois-crypto authored Feb 26, 2024
2 parents d9bb3b0 + 6e3732a commit 027cb87
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion solidity/src/FCL_elliptic.sol
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ function SqrtMod(uint256 self) internal view returns (uint256 result){
* @dev Check if a point in affine coordinates is on the curve (reject Neutral that is indeed on the curve).
*/
function ecAff_isOnCurve(uint256 x, uint256 y) internal pure returns (bool) {
if ( ((0 == x)&&( 0 == y)) || x == p || y == p) {
if ( ((0 == x)&&( 0 == y)) || (x == p && y == p)) {
return false;
}
unchecked {
Expand Down

0 comments on commit 027cb87

Please sign in to comment.