EIP-7807 · Draft · Core · 2024-10-28
EIP-7807: SSZ execution blocks
Proposes re-encoding execution blocks in SSZ instead of RLP, so the block hash becomes an SSZ hash_tree_root shared with the consensus layer and individual block fields become provable.
What problem does it solve?
Ethereum has two serialization worlds. The consensus layer uses SSZ (Simple Serialize) with Merkle hash_tree_root commitments. The execution layer encodes the block header in RLP, hashes it with keccak256, and commits to transactions, receipts and withdrawals with Merkle-Patricia tries. Every interaction between the two layers has to translate between them.
EIP-7807 moves the execution block to SSZ. The spec lists four benefits:
- The consensus layer can compute and check the execution block hash on its own, without asking the execution client.
- The Engine API could switch from JSON to binary SSZ, which the spec estimates roughly halves message size.
- Individual block fields become provable with small Merkle proofs, and proofs stay valid as the block evolves.
- PoW-era leftovers and the logs bloom can be dropped.
How it works
- A new SSZ
ExecutionPayloadreplaces the RLP header plus body. It is aProgressiveContainer(EIP-7495) with fields such asparent_hash,miner,state_root,transactions,receipts_root,number,gas_limits,gas_used,timestamp,base_fees_per_gas,withdrawals,excess_gas,requests_hash,block_access_listandslot_number. - Regular and blob gas are paired into one
GasAmountsstructure (and fees intoBlobFeesPerGas) instead of separate header fields. - Lists use
ProgressiveList(EIP-7916), so they have no hard-coded size limit and their Merkle positions stay stable. - Not changed: each transaction and receipt keeps its EIP-2718 typed-envelope bytes; withdrawals and the block access list keep RLP; the state trie is untouched.
- The block hash becomes
ExecutionPayload.hash_tree_root()everywhere:BLOCKHASH, JSON-RPCblockHash, devp2p and consensus-layer references. - A header is just an SSZ summary of the payload with the large lists replaced by their roots.
- JSON-RPC blocks report
logsBloomas all0xffbytes, forcing consumers to check receipts instead of trusting a bloom that no longer exists.
Sample code
The core container from the spec, in the consensus-specs Python style:
class GasAmounts(ProgressiveContainer(active_fields=[1] * 2)):
regular: GasAmount # uint64
blob: GasAmount
class ExecutionPayload(ProgressiveContainer(active_fields=[1] * 18)):
parent_hash: Root
miner: ExecutionAddress
state_root: Bytes32
transactions: ProgressiveList[ProgressiveByteList]
receipts_root: Root
number: uint64
gas_limits: GasAmounts
gas_used: GasAmounts
timestamp: uint64
# ... extra_data, mix_hash, base_fees_per_gas, withdrawals, excess_gas,
# parent_beacon_block_root, requests_hash, block_access_list, slot_number
block_hash = payload.hash_tree_root() # replaces keccak256(rlp(header))
Things to know
- Status is Draft. It is not in the scheduled list for Glamsterdam (EIP-7773).
- Contracts that parse RLP block headers (for example to verify a header against
BLOCKHASH) would break and need SSZ proof logic instead. - The new hash uses SHA-256 rather than keccak256. The spec considers collision risk with old keccak-based hashes negligible.
- The receipt-level
logsBloomis unaffected; only the block-level bloom is retired. - It builds on the Gloas payload envelope introduced with ePBS (EIP-7732).