This EIP defines a migration process of the existing Merkle-Patricia Trie (MPT) commitment for withdrawals to Simple Serialize (SSZ).
Motivation
While the consensus ExecutionPayloadHeader and the execution block header map to each other conceptually, they are encoded differently. This EIP aims to align the encoding of the withdrawals_root, taking advantage of the more modern SSZ format. This brings several advantages:
Reducing complexity: The proposed design reduces the number of use cases that require support for Merkle-Patricia Trie (MPT).
Reducing ambiguity: The name withdrawals_root is currently used to refer to different roots. The execution block header refers to a MPT root, the consensus ExecutionPayloadHeader refers to an SSZ root.
Specification
The key words “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”, “SHOULD NOT”, “RECOMMENDED”, “NOT RECOMMENDED”, “MAY”, and “OPTIONAL” in this document are to be interpreted as described in RFC 2119 and RFC 8174.
Existing definitions
Definitions from existing specifications that are used throughout this document are replicated here for reference.
When building a consensus ExecutionPayload, the withdrawals_root is now based on the Withdrawal SSZ container. Implementations that currently produce withdrawals in the EIP-4895 format can convert them using the normalize_withdrawal helper function.
The recover_encoded_withdrawal helper function recovers a withdrawal’s original representation for exchange through the devp2p Withdrawals message.
Rationale
This change was originally a candidate for inclusion in Shanghai, but was postponed to accelerate the rollout of withdrawals.
Backwards Compatibility
Applications that solely rely on the Withdrawal RLP encoding but do not rely on the withdrawals_root in the block header can still be used through a re-encoding proxy.
Applications that rely on the replaced MPT withdrawals_root in the block header can no longer find that information. Analysis is required whether affected applications have a migration path available to use the SSZ withdrawals_root instead.
Withdrawals were only just recently introduced as part of EIP-4895 (Shanghai). It is not expected that major applications already rely on the Merkle-Patricia Trie commitment for withdrawals.