From 435d4f4fafb5942405af64b7b19cc45d7ebf1104 Mon Sep 17 00:00:00 2001 From: terence tsao Date: Tue, 1 Aug 2023 15:31:47 -0700 Subject: [PATCH] add draft builder spec --- specs/_features/ePBS/builder.md | 41 +++++++++++++++++++++++++++ specs/_features/ePBS/p2p-interface.md | 4 +-- 2 files changed, 43 insertions(+), 2 deletions(-) create mode 100644 specs/_features/ePBS/builder.md diff --git a/specs/_features/ePBS/builder.md b/specs/_features/ePBS/builder.md new file mode 100644 index 0000000000..7a2f107c25 --- /dev/null +++ b/specs/_features/ePBS/builder.md @@ -0,0 +1,41 @@ +# ePBS -- Honest Builder + +**Notice**: This document is a work-in-progress for researchers and implementers. + + +## Introduction + +This document represents the changes to be made in the code of an "honest builder" to implement ePBS. + +## Becoming a builder + +### Initialization + +A builder must initialize many parameters locally before submitting a deposit and joining the builder registry. + +Refer BLS public key and Withdrawal credentials to phase 0 validator spec. + +### Submit deposit + +TODO: + + +## Beacon chain responsibilities + + +### Signed builder bid proposal + +At slot `N`, builder constructs `SignedBuilderBid` and broadcasts to `builder_bid` gossip topic for slot `N+1` block proposal. +Builder may submit multiple `SignedBuilderBid` for different chain tips, but builder should only submit one bid per chain tip. + + +### Signed builder bid reveal + +At slot `N+1`, builder observes proposer at `N+1` proposed a block using the bid constructed at `N`. If the proposer used the builder bid, the builder has to make a note for the following duty. + +At `SECONDS_PER_SLOT * 2 / INTERVALS_PER_SLOT` seconds, if the builder did not observe equivocation for the block, builder will reveal the payload by broadcasting it to the `execution_payload` gossip topic. By monitoring equivocation, this prevents same-slot unbundling. + + +### Signed builder bid reveal (conservative mode) + +Builder monitors all the beacon attestation subnets and observe all the attestations. Builder should not reveal payload if only few attestations for current slot and many attestations for parent slot and bid is not large enough. This prevents next-slot re-orging \ No newline at end of file diff --git a/specs/_features/ePBS/p2p-interface.md b/specs/_features/ePBS/p2p-interface.md index fcc0c1a513..e16bff87e9 100644 --- a/specs/_features/ePBS/p2p-interface.md +++ b/specs/_features/ePBS/p2p-interface.md @@ -51,7 +51,7 @@ This topic is used to propagate execution payload. The following validations MUST pass before forwarding the `execution_payload` on the network, assuming the alias `payload = execution_payload`: -- _[IGNORE]_ The payload aligns with header that received in block. +- _[IGNORE]_ The hash tree root of the payload matches the hash tree root of a payload header received previously on the `beacon_block` topic. ###### `execution_attestation` @@ -73,7 +73,7 @@ The following validations MUST pass before forwarding the `signed_builder_bid` o - _[REJECT]_ The signed builder bid pubkey, `bid.pubkey`, exists in state. - _[IGNORE]_ The signed builder bid value, `bid.value`, is less than builder's balance in state. - _[IGNORE]_ The signed builder header timestamp is correct with respect to next slot -- i.e. `header.timestamp == compute_timestamp_at_slot(state, current_slot + 1)`. -- _[IGNORE]_ The signed builder header parent block has matches one of the chain tip in the fork choice store. Builder may submit multiple bids with respect to forks. +-_[IGNORE]_ The signed builder header parent block matches one of the chain tip(s) in the fork choice store. Builder may submit multiple bids corresponding to various forks. - _[REJECT]_ The builder signature, `signed_bid.signature`, is valid with respect to the `bid.pubkey`. #### Transitioning the gossip