Skip to content

Commit

Permalink
don't modify verify_block_signature
Browse files Browse the repository at this point in the history
  • Loading branch information
potuz committed Aug 25, 2023
1 parent 8b69b9b commit 2a6400a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
13 changes: 0 additions & 13 deletions specs/_features/epbs/beacon-chain.md
Original file line number Diff line number Diff line change
Expand Up @@ -574,19 +574,6 @@ The post-state corresponding to a pre-state `state` and a signed block `signed_b

The post-state corresponding to a pre-state `state` and a signed execution payload `signed_execution_payload` is defined as `process_execution_payload(state, signed_execution_payload)`. State transitions that trigger an unhandled exception (e.g. a failed `assert` or an out-of-range list access) are considered invalid. State transitions that cause a `uint64` overflow or underflow are also considered invalid.

### Modified `verify_block_signature`

```python
def verify_block_signature(state: BeaconState, signed_block: SignedBeaconBlock) -> bool:
index = signed_block.message.proposer_index
if index < len(state.validators):
proposer = state.validators[index]
else:
proposer = state.builders[index-len(state.validators)]
signing_root = compute_signing_root(signed_block.message, get_domain(state, DOMAIN_BEACON_PROPOSER))
return bls.Verify(proposer.pubkey, signing_root, signed_block.signature)
```

### Epoch processing

#### Modified `process_epoch`
Expand Down
3 changes: 1 addition & 2 deletions specs/_features/epbs/fork-choice.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,5 +169,4 @@ def on_excecution_payload(store: Store, signed_envelope_: SignedExecutionPayload

#Add new state for this payload to the store
store.execution_payload_states[beacon_block_root] = state
```
```

0 comments on commit 2a6400a

Please sign in to comment.