Skip to content

p2p: rate-limit GETMNLISTDIFF per peer #7564

Description

@PastaPastaPasta

Motivation

GETMNLISTDIFF is unauthenticated, requires no proof of work, and is not currently rate limited. Even with bounded MN list caches (see #7485), a peer can still drive non-trivial CPU work by repeatedly requesting historical diffs.

#7485 adds hard caps and a stale LRU tier so memory and repeat stale access are bounded, but absolute request rate is still unconstrained at the P2P layer.

Proposal

Add per-peer rate limiting for GETMNLISTDIFF in net_processing.cpp, similar to other DoS-sensitive message handlers. Limits should be sized from honest traffic (masternode/wallet sync during chain catch-up) rather than attacker-only thresholds.

Related

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions