ERC-7965 Proof-based cross-chain broadcasting (Proof-based Broadcast in ERC-7786 Gateways)
Draft · Other · created 2025-06-06
This adds route and inclusionProof attributes to ERC-7786 gateways that verify messages using cryptographic proofs, enabling trustless cross-chain messaging without external validators and granular broadcasting.
Why it is needed
Cross-chain messaging usually relies on external validators, multisigs, or optimistic mechanisms to vouch for the authenticity of a message. This structure increases the number of parties that must be trusted, and if validators collude or fail, messages can be forged or blocked. ERC-7786 defined a basic framework for sending and receiving messages, but it did not specify the details needed to verify messages with cryptographic proofs, such as route information, proof data, and version checks. In addition, broadcasting only supported a full broadcast with all addresses filled with zeros, with no granular way to target specific chains or specific chain types. As a result, every project seeking to support trustless verification and granular broadcasting had to build its own distinct approach from scratch.
What to implement
route((bytes,bytes,uint256)[]): Specifies the verification path from the destination to the source chain as an array of tuples of per-hop address, proof, and version requirement.inclusionProof(bytes): A cryptographic proof that a specific message exists in the finalized block state of the source chain.targetBlock(uint256): Specifies the block number, or an equivalent commitment identifier, of the source chain at which the message was committed.
In depth
Broadcast granularity
ERC-7786 expressed a full broadcast using an ERC-7930 interoperable address with the recipient address filled entirely with zeros. This standard adds granular broadcasting by partially leaving fields of the ERC-7930 address structure empty. Setting AddressLength to 0 while specifying ChainType and ChainReference produces a broadcast to all addresses on a specific chain. Setting ChainReferenceLength to 0 while specifying only ChainType sends to the entire chain type (for example, all chains in the eip155 namespace). Setting all fields to 0 produces a full broadcast to all supported chains and addresses. Recipients must verify the origin and authenticity of a broadcast message according to their own security requirements.
The route attribute
The route((bytes,bytes,uint256)[]) attribute specifies the verification path from the destination chain to the source chain as an array of tuples of gateway address, proof, and version. The address at each hop must be called to verify the state or transaction history of the next chain, and if the version is nonzero, the gateway must reject the message unless the route address supports exactly that version. The route must form a valid path where each step represents a direct verification relationship between chains, and in a multi-hop scenario each step verifies the next, forming a chain of trust that ultimately establishes the authenticity of the source chain's state. If the proof data is invalid or incomplete, the gateway must reject the message.
The inclusionProof attribute
The inclusionProof(bytes) attribute is a cryptographic proof that a specific message actually exists in the committed state of a finalized block or transaction history on the source chain. On EVM chains, this usually takes the form of an event inclusion proof or a storage proof. ERC-7786 recipients must verify this proof according to the source chain's proof system. During verification, inclusionProof is used to confirm the existence of the message data against the target block obtained from route verification, and the source chain must match the step finally verified during route verification.
The targetBlock attribute
The targetBlock(uint256) attribute is an optional attribute that specifies the block number or height at which the message was committed on the source chain. On chains that do not use sequential block numbers, it refers to the equivalent commitment identifier. Recipients may use this value to verify freshness or finality requirements according to their own security policy, or ignore it if not needed. When a value is provided, it must match the block or commitment of the state that inclusionProof proves.
The six-step verification procedure
Message verification begins by parsing the route, inclusionProof, and, if present, targetBlock attributes from the message and confirming that all required attributes are present and well-formed. It then verifies the state commitment, such as a block hash transition, at each step of the route against the paired proof, checks version requirements if any, and uses inclusionProof to confirm that the message data exists in the source chain's committed state at the target block obtained from route verification. Finally, if targetBlock is provided and the recipient wants it, freshness or finality is optionally verified, and the message is executed once all verifications pass.
Relationship to existing proof protocols
This standard provides common properties so that EVM storage-proof protocols such as ERC-7888, or other proof systems, can implement an ERC-7786 gateway without rebuilding their core verification logic. For example, ERC-7888's Broadcaster can keep its existing storage-proof structure while using this standard's properties to expose an ERC-7786 interface. In multi-hop situations, each route step verifies the state commitment of the next chain, building a chain of trust from destination back to source, similar to ERC-7888's BlockHashProver chain.
Caching and Immutability
Gateways may implement caching mechanisms to optimize repeated proof verification. Proofs are deterministic, so they can be safely cached, which is especially useful for broadcast messages that must be verified multiple times. A gateway may also choose to guarantee immutability by committing messages in a way that cannot be erased or altered once committed. This is not required by this standard, but on an EVM chain the method of computing an immutable storage location's namespace via ERC-7201 can be used. Proving a commitment that can be deleted or modified creates an additional security risk: the proof itself may remain valid even after the message has been deleted.
Proposal status
This proposal is currently in Draft status, not yet finalized, and its details may change or discussion may stall.
Things to watch out for
- Strict Validation of Proof Data: To prevent message forgery, gateways must thoroughly validate the format, completeness, and cryptographic validity of proofs. Route addresses must match legitimate proof infrastructure forming a valid, connected path between chains, and only finalized blocks or equivalent commitment points should be used to generate proofs, to prevent reorg attacks.
- Freshness Checks for Stale Messages: Because a proof can be validly verified against any past block or commitment, it is possible to prove very old messages. Consumers of messages must implement appropriate freshness checks; this check is not strictly necessary if the gateway only provides immutable commitments.
- Multi-Hop Route Security Is Determined by the Weakest Link: When using a route that traverses multiple steps, the step with the weakest cryptographic guarantees or consensus mechanism determines the overall security level. Implementers must carefully evaluate each hop and consider the cumulative security impact.
- Verifying the Sender and Content of Broadcast Messages: Because broadcast messages can be executed by anyone, recipients must strongly validate the message's origin and content, including the sender's authority and the message's semantic validity.