agents/skills/injectable/l1/gossip-cache-invariance/SKILL.md
L1 trigger - audits message and seen caches for write-after-validate ordering, eviction safety, and duplicate handling.
npx skillsauth add plamentsv/plamen gossip-cache-invarianceInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
L1 trigger:
P2Pflag AND (seen_cache,message_cache,tx_cache,gossipsub,pubsub,dedup,seen_chunksdetected) Inject Into:depth-network-surface,depth-consensus-invariantLanguage: Go and Rust Finding prefix:[GCI-N]
For each attacker-controlled cache key, prove the ordering between cache write and integrity/authenticity validation. Cache insertion before validation is a poisoning primitive.
Tag: [GOSSIP-CACHE:ORDER]
Check whether duplicate suppression is keyed on canonical content, the right topic/partition, and enough sender identity. Look for cases where legitimate messages are suppressed or malicious messages can be replayed after eviction.
Tag: [GOSSIP-CACHE:DUPLICATES]
Under burst traffic or memory pressure:
Tag: [GOSSIP-CACHE:EVICTION]
Verify the key includes the right tuple of topic / partition / chain / message identity. Flag collisions where distinct messages alias to the same cache key.
Tag: [GOSSIP-CACHE:KEY]
State the resulting invariant failure explicitly:
For each receive-and-rebroadcast path:
If a cache miss multiplies traffic or work across peers, record it as an amplification finding rather than a simple duplicate-handling bug.
Tag: [GOSSIP-CACHE:AMPLIFICATION]
When a chunk / block / attestation cache is indexed by a property derived from the canonical chain (slot, epoch, partition id, shard id), a reorg can move the canonical chain underneath entries that are no longer valid for the new chain but still satisfy the cache key.
Check:
{piece_id, partition_id} tuple the
full cache key, or is partition_id inferred from head and therefore
mutable? If inferred, a reorg silently re-labels cached pieces.Tag: [GOSSIP-CACHE:REORG-POISON:{cache}:{scenario}]. Severity defaults
to High when the cache influences consensus weight or censors a legitimate
message class; Medium when it only amplifies work.
development
Prepare Solidity projects for a security audit — test coverage, test quality, NatSpec docs, code hygiene, dependency health, best-practice enforcement, deployment readiness, and project documentation checks. Generates a scored Audit Readiness Report and optionally runs static analysis. Trigger on: "prepare for audit", "audit readiness", "pre-audit check", "audit prep", "NatSpec check", or any request to review a Solidity codebase before a security review.
development
Launch the Plamen deterministic Web3 security audit pipeline
development
Run the Plamen smart-contract audit wizard in Codex
testing
Launch the Plamen deterministic L1 infrastructure audit pipeline