-
Notifications
You must be signed in to change notification settings - Fork 22
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
Implementation of Pallas #14
Conversation
This PR now just covers the Pallas implementation. Test vectors are in subsequent PRs like #17. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK
Co-authored-by: Daira Hopwood <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK with non-blocking comments/nits.
def __init__(self, x, y): | ||
self.x = x | ||
self.y = y | ||
self.is_identity = False |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be cool to have an is_on_curve assertion here; y^2 == x^3 + b
.
assert Point.ZERO + Point.ZERO == Point.ZERO | ||
assert Point.GENERATOR - Point.GENERATOR == Point.ZERO | ||
assert Point.GENERATOR + Point.GENERATOR + Point.GENERATOR == Point.GENERATOR * Scalar(3) | ||
assert Point.GENERATOR + Point.GENERATOR - Point.GENERATOR == Point.GENERATOR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A good test is assert (-Point.GENERATOR) == Point.GENERATOR * -Scalar(-1)
.
No description provided.