HomePhabricator

test: p2p: remove tests for header messages that are oversized due to the…

Description

test: p2p: remove tests for header messages that are oversized due to the MAX_HEADERS_RESULTS limit

Summary:
The headers message has a size limit, determined by the number of headers, which is triggered at approximately 160,000 bytes (80 bytes × 2,000 headers), about one order of magnitude below the tested message sizes. Logs show the node rejecting these messages, as indicated by the following lines:

Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 2097146
Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 1999996
Misbehaving: peer=0 (0 -> 20): too-many-headers: headers message size = 999996

So contrary to the intent of the test, the tested network messages are no in fact "not_oversized_msg".

In a future diff the misbehavior score increment will be bumped from 20 to 100, and the peer will actually be disconnected, which would cause the removed tests to fail on conn.send_and_ping.

See D16343 for why these tests where added.

Depends on D18025

Test Plan: test/functional/test_runner.py p2p_invalid_messages

Reviewers: #bitcoin_abc, roqqit

Reviewed By: #bitcoin_abc, roqqit

Subscribers: roqqit

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

Details

Provenance
PiRKAuthored on Wed, Apr 30, 12:09
PiRKPushed on Wed, Apr 30, 17:02
Reviewer
Restricted Project
Differential Revision
D18026: test: p2p: remove tests for header messages that are oversized due to the MAX_HEADERS_RESULTS limit
Parents
rABCd3e0e4bc4631: test: p2p: check misbehavior for non-continuous headers messages
Branches
Unknown
Tags
Unknown