Skip to content

crypto/bn256: fix incorrect constant in MulXi#34659

Open
aso20455 wants to merge 1 commit intoethereum:masterfrom
aso20455:fix/bn256-mulxi-comment
Open

crypto/bn256: fix incorrect constant in MulXi#34659
aso20455 wants to merge 1 commit intoethereum:masterfrom
aso20455:fix/bn256-mulxi-comment

Conversation

@aso20455
Copy link
Copy Markdown
Contributor

@aso20455 aso20455 commented Apr 4, 2026

The comment formula showed (i+3) but the code multiplies by 9 (Lsh 3 + add = 8+1).
This was a error when porting from upstream golang.org/x/crypto/bn256 where ξ=i+3.
Go-ethereum changed the constant to ξ=i+9 but forgot to update the inner formula.

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.

1 participant