-
Notifications
You must be signed in to change notification settings - Fork 205
refactor: hash to curve #674
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
Conversation
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.
Copilot reviewed 71 out of 71 changed files in this pull request and generated no comments.
Currently not yet ready, I'll confirm it would also be useful for map to G2 in gnark. |
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.
Copilot reviewed 71 out of 71 changed files in this pull request and generated no comments.
@ThomasPiellard, @Tabaie - ready for review now. |
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.
I don't think it makes a lot of sense to have hash_to_curve
source files in both packages. imo every hash to curve function should be moved to the new package and only add a few wrappers to the root package, thus removing hash_to_g{{i}}.go
from the root package. This way we can avoid making all those internal functions public as well.
The goal of the PR is to make some internal things public so that we can reuse in gnark:
For the For the Isogeny methods I overcame that by working directly with the point coordinates. I could have done it also for |
98b60e1
to
c7145fa
Compare
This reverts commit 63fd519.
c7145fa
to
6b6896c
Compare
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.
Thanks looks good
Description
This PR exposes the primitive methods of hash-to-curve so that it can be implemented in gnark. Also separated the code generation into separate method.
Kept the current public methods intact, so it is fully backwards compatible.
Type of change
Checklist:
golangci-lint
does not output errors locally