-
Notifications
You must be signed in to change notification settings - Fork 871
[Merged by Bors] - Implement slasher #1567
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
Conversation
2b3c1a6
to
039b066
Compare
This is faster, and pushes a lot of the work into tree hashing, which we might be able to optimise.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an impressive research and engineering piece! It was a pleasure to read and a real contribution to Lighthouse and Eth2 🥇
I must admit I'm not 100% across the theory of the schema, but I don't think that should prevent a merge. The slasher is a best-effort component; as long as it does not crash then it is better than nothing. That being said, I see no reason to believe this implementation is lacking.
Although I'm not fully across the slasher theory, I did go through the whole implementation and have left several comments and suggestions. I would be happy to merge
🚀
This is ready for re-review and merge IMO. The only outstanding issue is #1890, which I'll try to get to before 1.0, but isn't a blocker for users running with the default configuration, or experienced users (who can drop their DB if they set a max DB size too low). |
Will fix the merge conflict ASAP, just finishing off some slashing protection stuff |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, LGTM!
Happy for you to bors whenever, assuming merge conflict change is trivial :)
Indeed the merge commit was trivial (97228b5) I can't believe we're finally merging this 😮 😮 😮 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 🚀 Summoning Señor Bors... bors r+ |
This is an implementation of a slasher that lives inside the BN and can be enabled via `lighthouse bn --slasher`. Features included in this PR: - [x] Detection of attester slashing conditions (double votes, surrounds existing, surrounded by existing) - [x] Integration into Lighthouse's attestation verification flow - [x] Detection of proposer slashing conditions - [x] Extraction of attestations from blocks as they are verified - [x] Compression of chunks - [x] Configurable history length - [x] Pruning of old attestations and blocks - [x] More tests Future work: * Focus on a slice of history separate from the most recent N epochs (e.g. epochs `current - K` to `current - M`) * Run out-of-process * Ingest attestations from the chain without a resync Design notes are here https://hackmd.io/@sproul/HJSEklmPL
Pull request successfully merged into master. Build succeeded: |
This is an implementation of a slasher that lives inside the BN and can be enabled via
lighthouse bn --slasher
.Features included in this PR:
Future work:
current - K
tocurrent - M
)Design notes are here https://hackmd.io/@sproul/HJSEklmPL