EIP-8025 -- The Beacon Chain
Note: This document is a work-in-progress for researchers and implementers.
Table of contents
Introduction
These are the beacon-chain specifications to add EIP-8025, enabling stateless
validation of execution payloads through execution proofs.
Note: This specification is built upon Gloas
and imports proof types from proof-engine.md.
Types
New ProofData
| class ProofData(ProgressiveByteList):
"""
The opaque proof bytes of an execution proof.
"""
|
New ProofType
| class ProofType(Uint8):
"""
The identifier of the proof system that produced an execution proof.
"""
|
Constants
Execution
Note: The execution values are not definitive.
| Name |
Value |
MAX_PROOF_SIZE |
Uint64(4194304) (= 4,096 KiB, 4 MiB) |
Domains
| Name |
Value |
DOMAIN_EXECUTION_PROOF |
DomainType('0x0F000000') |
Containers
| class PublicInput(Container):
new_payload_request_root: Root
|
New ExecutionProof
| class ExecutionProof(Container):
proof_data: ProofData
proof_type: ProofType
public_input: PublicInput
|
New SignedExecutionProof
| class SignedExecutionProof(Container):
message: ExecutionProof
validator_index: ValidatorIndex
signature: BLSSignature
|
Beacon chain state transition function
Execution proof
Note: Proof storage is implementation-dependent, managed by the ProofEngine.
New process_execution_proof
| def process_execution_proof(
state: BeaconState,
signed_proof: SignedExecutionProof,
proof_engine: ProofEngine,
) -> None:
proof_message = signed_proof.message
assert len(proof_message.proof_data) <= MAX_PROOF_SIZE
# Verify prover is an active validator
validator = state.validators[signed_proof.validator_index]
assert is_active_validator(validator, get_current_epoch(state))
domain = get_domain(state, DOMAIN_EXECUTION_PROOF, compute_epoch_at_slot(state.slot))
signing_root = compute_signing_root(proof_message, domain)
assert bls.Verify(validator.pubkey, signing_root, signed_proof.signature)
# Verify the execution proof
assert proof_engine.verify_execution_proof(proof_message)
|