HomePhabricator

net_processing: drop Misbehavior for unconnecting headers

Description

net_processing: drop Misbehavior for unconnecting headers

Summary:
This misbehavior was originally intended to prevent bandwidth wastage due to
actually observed very broken (but likely non-malicious) nodes that respond
to GETHEADERS with a response unrelated to the request, triggering a request
cycle.

This has however largely been addressed by the previous commit, which causes
non-connecting HEADERS that are received while a GETHEADERS has not been
responded to, to be ignored, as long as they do not time out (2 minutes).
With that, the specific misbehavior is largely irrelevant (for inbound peers,
it is now harmless; for outbound peers, the eviction logic will eventually
kick them out if they're not keeping up with headers at all).

This is a partial backport of core#29575
https://github.com/bitcoin/bitcoin/pull/29575/commits/944c54290d5c081dc433dae7e7941074a3a8b5a7
Depends on D18029

Test Plan: ninja all check-all

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D18030

Details

Provenance
Pieter Wuille <pieter@wuille.net>Authored on Mar 7 2024, 16:22
PiRKCommitted on Thu, May 1, 13:40
PiRKPushed on Thu, May 1, 13:40
Reviewer
Restricted Project
Differential Revision
D18030: net_processing: drop Misbehavior for unconnecting headers
Parents
rABCeb691e693a26: net_processing: do not treat non-connecting headers as response
Branches
Unknown
Tags
Unknown