OpenZeppelin / OpenZeppelin/compact-contracts

Add Jubjub curve primitives module

Open
#549 0 comments 0 reactions 1 assignee View on GitHub

@0xisk is already working on this.

Since Jul 9, 2026.

1-medium effort: 3-M feat:crypto
Dominant language
TypeScript
Stars
55
Forks
29
Avg merge
5d 7h
Merged PRs (30d)
25

Description

🧐 Motivation
The embedded-Jubjub modules (Schnorr #548, Pedersen, ring signatures, FROST) all re-need the same low-level curve helpers. A shared primitives module avoids duplication and centralizes the scalar-fitting trick that unblocks the EmbeddedFr decode error in ecMul / ecMulGenerator.

📝 Details
Reusable primitives for the Jubjub embedded curve (over BLS12-381's scalar field): pointsEqual, isIdentity, assertNonIdentity, fitInJubjubScalar (truncates a Field into [0, 2^248) ⊂ [0, Fr) so it is a valid Jubjub scalar for ecMul / ecMulGenerator). Shared by the Schnorr (#548) / Pedersen / ring-signature / FROST modules. PoC: crypto/Jubjub.compact in #521.
Roadmap: Libraries → Jubjub Curve Primitives (Priority MNF: medium).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.