Skip to content

fix: set correct Jubjub curve generator#821

Open
sug0 wants to merge 2 commits intoConsensys:masterfrom
heliaxdev:tiago/jubjub-fix-generator
Open

fix: set correct Jubjub curve generator#821
sug0 wants to merge 2 commits intoConsensys:masterfrom
heliaxdev:tiago/jubjub-fix-generator

Conversation

@sug0
Copy link
Copy Markdown

@sug0 sug0 commented Mar 17, 2026

Description

Closes #805

This PR fixes the Jubjub curve generator. The linked issue contains a few more details.


Note

Medium Risk
Updates the Jubjub (twisted Edwards over BLS12-381 Fr) base point coordinates; this affects cryptographic correctness and may change derived keys/signatures, but the change is limited to constant parameters.

Overview
Fixes the Jubjub generator by replacing the twisted Edwards base point coordinates for BLS12-381/Fr.

The updated base point is applied consistently in both the generated curve parameters (ecc/bls12-381/twistededwards/curve.go) and the curve generator config (internal/generator/config/bls12-381.go).

Written by Cursor Bugbot for commit 028f330. This will update automatically on new commits. Configure here.

@sug0 sug0 changed the title Fix Jubjub curve generator fix: set correct Jubjub curve generator Mar 17, 2026
@sug0
Copy link
Copy Markdown
Author

sug0 commented Mar 17, 2026

/cc @ivokub review requested, I would appreciate merging this PR, since it's pretty self contained, and the changes are pretty obvious. cheers!

@ivokub
Copy link
Copy Markdown
Collaborator

ivokub commented Mar 25, 2026

/cc @ivokub review requested, I would appreciate merging this PR, since it's pretty self contained, and the changes are pretty obvious. cheers!

Thanks for the PR and I will review the PR soon.

What makes it a bit dangerous is that we have to consider backwards compatibility as well (in case someone already uses the current base generator), so not so straightforward to just merge as is.

Just in case - perhaps we could define an alternative approach i.e. have another generator getter and mark the current one as deprecated?

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.

bug: Invalid Jubjub curve generator

2 participants