Skip to content

docs: add probe-triggered eviction hold to prevent false slashing - #132

Merged
thiras merged 2 commits into
mainfrom
fix/probe-eviction-hold-117
Apr 2, 2026
Merged

thiras merged 2 commits into
mainfrom
fix/probe-eviction-hold-117

Conversation

@thiras

@thiras thiras commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Introduces a probe-triggered eviction hold mechanism: nodes MUST pin blobs against LRU/LFU eviction for 35 seconds after signing has_blob: true in a ProbeResponse, preventing legitimate cache eviction from producing false phantom-announcement slash evidence
  • Adds EvictedSinceProbe error variant to StreamError for observability when the hold budget is exhausted
  • Replaces the incorrect "eviction implausible" assumption in ADR 003 with the hold requirement, and documents the edge case that under-provisioned nodes accept the slash

Affected ADRs: 001, 003, 005, architecture.md

Closes #117

Test plan

  • Grep all ADRs for evict, phantom, has_blob, probe_hold, 35 to confirm cross-ADR consistency
  • Verify all new dependent parameters (probe_hold_duration, max_probe_holds) are documented in both the defining ADR (005) and cross-referenced ADRs (001, 003)
  • Confirm architecture.md summary reflects the new mechanism
  • Verify the "eviction implausible" claim is fully removed
  • Check all cross-references link to correct anchors

🤖 Generated with Claude Code

…R 003, 005)

A blob legitimately evicted by LRU between a probe (has_blob: true) and
a stream request produced phantom-announcement slash evidence against
honest nodes. Replace the incorrect "eviction implausible" assumption
with a probe-triggered eviction hold: nodes pin blobs for 35s after
signing has_blob: true, bounded by a configurable max_probe_holds budget.

Closes #117

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
Copilot AI review requested due to automatic review settings April 2, 2026 14:37

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the protocol/design ADRs to require a probe-triggered eviction hold after a node signs has_blob: true, preventing legitimate cache eviction from producing false phantom-announcement slashing evidence within the 30s slashing window.

Changes:

  • Specify a probe-triggered eviction hold (probe_hold_duration, max_probe_holds) in ADR 005 and propagate the requirement into ADRs 001/003 and the architecture summary.
  • Add StreamError::EvictedSinceProbe semantics for observability when a node loses a blob between probe and stream.
  • Remove/replace the prior “eviction implausible” framing with explicit hold requirements and an under-provisioning edge-case policy.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.

File Description
adr/architecture.md Extends cache eviction description to include the probe-triggered eviction hold.
adr/005-protocol.md Defines the hold mechanism/budget and adds EvictedSinceProbe to StreamError with semantics.
adr/003-payments.md Updates phantom announcement slashing rationale to require the hold and documents the hold-violation edge case.
adr/001-network.md Documents probe-cache interactions/observability expectations under the hold requirement.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread adr/architecture.md Resolved
Comment thread adr/005-protocol.md Resolved
Comment thread adr/005-protocol.md Resolved
Comment thread adr/003-payments.md Resolved
Comment thread adr/001-network.md Resolved
Comment thread adr/001-network.md Resolved

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a probe-triggered eviction hold mechanism to prevent phantom-announcement slashing by requiring nodes to pin blobs for 35 seconds after a positive probe. It defines a hold budget and a new EvictedSinceProbe error code. Review feedback identifies logical inconsistencies in the documentation regarding budget enforcement, highlights potential Denial-of-Service vulnerabilities in the global hold budget, and notes that the new error code remains slashable evidence if signed. Recommendations were also made to increase default budget limits and use 'MUST NOT' for retry policies.

Comment thread adr/005-protocol.md Resolved
Comment thread adr/001-network.md Resolved
Comment thread adr/005-protocol.md Resolved
Comment thread adr/005-protocol.md Resolved
Comment thread adr/005-protocol.md Resolved
- Promote eviction hold and hold budget to #### subsections for stable
  cross-reference anchors
- Use probe_hold_duration parameter name instead of hard-coded "35 seconds"
  across ADRs 001, 003, and architecture.md to prevent drift
- Acknowledge Sybil DoS vector on global hold budget (availability
  degradation, not safety violation)
- Fix EvictedSinceProbe semantics: warn that ok:false is still slash
  evidence, use MUST NOT for retry, clarify high error rates indicate
  hold mechanism failure not budget misconfiguration
- Label 1% observability threshold as rough heuristic, not protocol
  requirement
- Note holds are per-blob (shared across probing peers) and production
  nodes should increase default

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
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.

docs: address legitimate cache eviction being falsely slashable

2 participants