Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Harden block proposal against expired slashings/exits #4013

Merged
merged 2 commits into from
Aug 23, 2022
Merged

Conversation

arnetheduck
Copy link
Member

When a message is signed in a phase0 domain, it can no longer be
validated under bellatrix due to the correct fork no longer being
available in the BeaconState.

To ensure that all slashing/exits are still valid, in this PR we re-run
the checks in the state that we're proposing for, thus hardening against
both signatures and other changes in the state that might have
invalidated the message.

When a message is signed in a phase0 domain, it can no longer be
validated under bellatrix due to the correct fork no longer being
available in the `BeaconState`.

To ensure that all slashing/exits are still valid, in this PR we re-run
the checks in the state that we're proposing for, thus hardening against
both signatures and other changes in the state that might have
invalidated the message.
in case of attestation slashing of multiple validators in one go
@arnetheduck
Copy link
Member Author

Hats off to @paulhauner for this one!

@github-actions
Copy link

Unit Test Results

       12 files  ±0       864 suites  ±0   1h 11m 27s ⏱️ - 3m 50s
  1 989 tests +1    1 842 ✔️ +1  147 💤 ±0  0 ±0 
10 690 runs  +4  10 500 ✔️ +4  190 💤 ±0  0 ±0 

Results for commit 14f97d8. ± Comparison against base commit f1ddcff.

@zah
Copy link
Contributor

zah commented Aug 23, 2022

Will there be a spec change for this?

@arnetheduck
Copy link
Member Author

Will there be a spec change for this?

this has been in the spec since phase0 but it only becomes an issue now with a third fork (the beaconstate holds two forks, current and previous)

@zah zah merged commit 9e9db21 into unstable Aug 23, 2022
@zah zah deleted the harden-exits branch August 23, 2022 15:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants