Skip to content

Conversation

@hadv
Copy link
Owner

@hadv hadv commented Dec 19, 2025

Summary

This PR implements an offline node slashing mechanism to ensure network liveness (Leader-Based Tracking).

Changes

  • Storage: Added inactivity_scores to ConsensusState.
  • Logic:
    • Decrement score for successful block authors.
    • Increment score for leaders of timed-out views.
    • Penalty: 10 units slashed immediately on timeout.
    • Removal: Validator removed from committee if score > 50.
  • Verification: added tests/liveness_test.rs.
  • Fix: Improved scripts/test_failure.sh robustness.

Testing

Run cargo test --test liveness_test

- Add inactivity_scores to ConsensusState
- Implement liveness tracking in VM execution
- Add incremental penalty (10 units) for missed leader slots
- Add committee removal threshold (50 net inactivity score)
- Add verification test (liveness_test.rs)
- Fix responsiveness issues in scripts/test_failure.sh
@hadv hadv force-pushed the feat/offline-slashing branch from 71f1a8c to 954c56a Compare December 19, 2025 05:33
@hadv hadv merged commit ea50480 into main Dec 19, 2025
2 checks passed
@hadv hadv deleted the feat/offline-slashing branch December 20, 2025 08:59
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.

3 participants