Add EIP-2537 BLS12-381 precompiles for trustless Ethereum bridging#2895
Open
iownducks wants to merge 2 commits intosei-protocol:mainfrom
Open
Add EIP-2537 BLS12-381 precompiles for trustless Ethereum bridging#2895iownducks wants to merge 2 commits intosei-protocol:mainfrom
iownducks wants to merge 2 commits intosei-protocol:mainfrom
Conversation
…ion, tests, documentation, and integration into the precompile setup.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the seven EIP-2537 BLS12-381 precompiled contracts to Sei's
EVM at addresses
0x0b–0x11, aligning Sei with Ethereum'sPectra upgrade. This enables Sei smart contracts to natively
verify Beacon Chain validator BLS signatures, which is the
foundation for building a fully trustless light-client bridge
between Sei and Ethereum.
Motivation
Today, bridges between Sei and Ethereum rely on multisigs or
oracle committees — trusted intermediaries that introduce security
assumptions and attack surface. Ethereum's consensus layer signs
everything with BLS12-381. By adding native support for these
curve operations, Sei contracts can directly verify those
signatures on-chain, removing the need for trusted third parties.
What's included
PAIRING_CHECK, MAP_FP_TO_G1, MAP_FP2_TO_G2
gnark-cryptolibrary — no custom curve mathdiscount tables
checks, subgroup membership enforcement
costs, and address verification
BLSCheck.sol) for on-chainverification
Files changed
precompiles/bls/bls.goprecompiles/bls/bls_test.go|
|
precompiles/bls/abi.json| Empty (raw precompiles don't useABI encoding) |
|
precompiles/setup.go| Register BLS precompiles in Sei'sprecompile system |
|
contracts/BLSCheck.sol| Solidity contract to verifyprecompiles work on-chain |
|
SIP-EIP-2537-BLS.md| Proposal document ||
go.mod| Dependency cleanup |Test plan
go test ./precompiles/bls/ -v)precompilespackage builds cleanlygofmtcompliantBLSCheck.solon devnet