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

Add tom 256 #941

Conversation

ineiti
Copy link

@ineiti ineiti commented Feb 21, 2025

Description

Add the Tom-256 curve from https://eprint.iacr.org/2021/1183 and described in https://neuromancer.sk/std/other/Tom-256

closes: #923


Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

  • Targeted PR against correct branch (master)
  • Linked to GitHub issue with discussion and accepted design OR have an explanation in the PR that describes this work.
  • Wrote unit tests
  • Updated relevant documentation in the code
  • Added a relevant changelog entry to the Pending section in CHANGELOG.md
  • Re-reviewed Files changed in the GitHub PR explorer

@ineiti ineiti requested review from a team as code owners February 21, 2025 15:14
@ineiti ineiti requested review from Pratyush, mmagician and weikengchen and removed request for a team February 21, 2025 15:14
@z-tech

This comment was marked as outdated.

@z-tech
Copy link
Contributor

z-tech commented Feb 27, 2025

@ineiti the error you see is fixed in this PR: #946

@ineiti
Copy link
Author

ineiti commented Feb 28, 2025

Wrt devbox.* - I like devbox to have a "out of the box shell environment". It uses nix to provide a development shell based on changing the PATH. But it should probably be in a separate PR, I'll remove it.

I squashed the commits and removed devbox. I also rebased on your PR.

@ineiti ineiti changed the base branch from master to z-tech/fix-werror-on-must-use-annotation February 28, 2025 14:21
@Pratyush Pratyush deleted the branch arkworks-rs:z-tech/fix-werror-on-must-use-annotation March 3, 2025 19:44
@Pratyush Pratyush closed this Mar 3, 2025
@ineiti
Copy link
Author

ineiti commented Mar 3, 2025

@Pratyush why did you close this PR? I made it depend on the z-tech/fix-werror-on-must-use-annotation to get the CI running, but it is an independent PR.

@Pratyush
Copy link
Member

Pratyush commented Mar 4, 2025

Hm I didn't close it. I think GitHub automatically closes PRs which don't have a base. Could you rebase to master? Thank you, and sorry for the trouble!

Copy link
Member

@Pratyush Pratyush left a comment

Choose a reason for hiding this comment

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

Left some small tweaks.

use ark_secp256k1::{fq::Fq, fr::Fr, Projective as G};

bench!(
Name = "Secp256k1",
Copy link
Member

Choose a reason for hiding this comment

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

I think this is a copy-paste error?

Comment on lines +4 to +5
/// A group element in the secp256k1 curve.
pub type GVar = ProjectiveVar<Config, FqVar>;
Copy link
Member

Choose a reason for hiding this comment

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

Same here?

@@ -0,0 +1,7 @@
//! This module implements the R1CS equivalent of `ark_secp256k1`.
Copy link
Member

Choose a reason for hiding this comment

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

Ditto?

Comment on lines +6 to +7
// #[small_subgroup_base = "3"]
// #[small_subgroup_power = "1"]
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// #[small_subgroup_base = "3"]
// #[small_subgroup_power = "1"]

Comment on lines +6 to +7
// #[small_subgroup_base = "3"]
// #[small_subgroup_power = "1"]
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// #[small_subgroup_base = "3"]
// #[small_subgroup_power = "1"]

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.

Add tom-256 curve
3 participants