Skip to content

Add bn254 support#1615

Merged
tomerweller merged 13 commits intostellar:p25-previewfrom
sisuresh:bn254
Nov 11, 2025
Merged

Add bn254 support#1615
tomerweller merged 13 commits intostellar:p25-previewfrom
sisuresh:bn254

Conversation

@jayz22
Copy link
Copy Markdown
Contributor

@jayz22 jayz22 commented Nov 11, 2025

What

This is the same PR as #1613, but onto p25-preview branch instead of master, so that it doesn't interfere with any potential p24 patch work.

All comments have been addressed in the original PR.

@socket-security
Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedark-bn254@​0.4.010010093100100

View full report

@tomerweller tomerweller merged commit 3cf10a9 into stellar:p25-preview Nov 11, 2025
210 of 211 checks passed
github-merge-queue bot pushed a commit that referenced this pull request Jan 12, 2026
### What

* Add bn254 support (#1615, #1628)
- A new module `crypto/bn254.rs` with Bn254 point and field types, and
expose related host operations.
  - Implement `Neg` trait for `G1Affine` (#1630)
- Update bn254 typenames and add mapping (#1645), also updated bls12-381
type names for consistency
* Add raw Poseidon, Poseidon2 support in `CryptoHazmat`, gated by
"hazmat-crypto" feature


### Why

Expose new crypto functions for protocol 25

### Known limitations

Only the raw host function exposure for Poseidon/Poseidon2 has been
added in this PR. The more elaborate setup for sponge, parameters, hash
function wrappers will be done in a separate repo
[here](https://github.com/stellar/rs-soroban-poseidon)

---------

Co-authored-by: Jay Geng <jay@stellar.org>
Co-authored-by: Siddharth Suresh <siddharth@stellar.org>
Co-authored-by: Leigh <351529+leighmcculloch@users.noreply.github.com>
Co-authored-by: Matteo Lisotto <matteo.lisotto@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Nando Vieira <me@fnando.com>
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.

4 participants