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

Generate Poseidon round parameters and constants #50

Open
3 of 6 tasks
s1fr0 opened this issue Sep 26, 2022 · 0 comments · Fixed by #51 or #53
Open
3 of 6 tasks

Generate Poseidon round parameters and constants #50

s1fr0 opened this issue Sep 26, 2022 · 0 comments · Fixed by #51 or #53
Labels
track:zerokit Zerokit track (Applied ZK/Explorations)

Comments

@s1fr0
Copy link
Contributor

s1fr0 commented Sep 26, 2022

Problem

We would like to have a self-contained poseidon module that works natively with arkworks traits, so that round parameters and constants are generated directly from the field characteristic and not hard-coded as now are. This will further enable current and future zerokit modules that use it to access the same Poseidon implementation.

In order to achieve such goal, we can progressively refactor the poseidon implementation currently present in the rln module.

The main required steps should be:

  • Implement GrainLFSR in order to generate constants from hard-coded round parameters (i.e., the tuples (t, RF, RP)) and field characteristic;
  • Pass arkworks PrimeField trait to Poseidon, so that the latter can be instantiated using different curves;
  • Generate in-code round parameters, i.e. port generate_params_poseidon.sage
  • Implement algorithm 1-2-3 from reference implementation to check security of randomly generated MDS matrices. Before implementing these algorithms, we hard-code the number of randomly generated unsecure matrices that should be skipped during generation (value taken from reference implementation);
  • Move the poseidon implementation to a separate module, e.g. under utils. This step can be done at any moment.

Acceptance Criteria

  • Implement all the above steps.
@s1fr0 s1fr0 added the track:zerokit Zerokit track (Applied ZK/Explorations) label Sep 26, 2022
@s1fr0 s1fr0 self-assigned this Sep 26, 2022
This was linked to pull requests Sep 28, 2022
@s1fr0 s1fr0 removed their assignment Sep 29, 2022
@s1fr0 s1fr0 mentioned this issue Jan 9, 2023
25 tasks
@s1fr0 s1fr0 moved this to Later/Icebox in Vac Research Jan 16, 2023
@rymnc rymnc mentioned this issue May 2, 2023
5 tasks
@rymnc rymnc added this to the Release v0.3.0 milestone May 2, 2023
@rymnc rymnc removed this from the Release v0.3.0 milestone Jul 31, 2023
@rymnc rymnc mentioned this issue Jul 29, 2024
12 tasks
@seemenkina seemenkina mentioned this issue Oct 4, 2024
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
track:zerokit Zerokit track (Applied ZK/Explorations)
Projects
Status: Later/Icebox
Development

Successfully merging a pull request may close this issue.

2 participants