Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix rejecting public keys of the form (0, y) #16

Merged
merged 2 commits into from
Sep 25, 2023

Conversation

nalinbhardwaj
Copy link
Member

Veridise Audit ID 10

Copy link
Member

@dcposch dcposch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM and as far as I can tell the math matches

@@ -105,7 +105,7 @@ contract P256Verifier {
uint256 x,
uint256 y
) internal pure returns (bool) {
if (0 == x || x >= p || 0 == y || y >= p) {
if (x >= p || y >= p || (x == 0 && y == 0)) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@nalinbhardwaj nalinbhardwaj merged commit 301328c into master Sep 25, 2023
3 checks passed
@nalinbhardwaj nalinbhardwaj deleted the nibnalin/inf-point branch September 25, 2023 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants