mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 14:38:29 +01:00
Support up to 3 parallel compact block txn fetchings
A single outbound slot is required, so if the first two slots are taken by inbound in-flights, the node will reject additional unless they are coming from outbound. This means in the case where a fast sybil peer is attempting to stall out a node, a single high bandwidth outbound peer can mitigate the attack.
This commit is contained in:
@@ -22,6 +22,8 @@ static const bool DEFAULT_PEERBLOOMFILTERS = false;
|
||||
static const bool DEFAULT_PEERBLOCKFILTERS = false;
|
||||
/** Threshold for marking a node to be discouraged, e.g. disconnected and added to the discouragement filter. */
|
||||
static const int DISCOURAGEMENT_THRESHOLD{100};
|
||||
/** Maximum number of outstanding CMPCTBLOCK requests for the same block. */
|
||||
static const unsigned int MAX_CMPCTBLOCKS_INFLIGHT_PER_BLOCK = 3;
|
||||
|
||||
struct CNodeStateStats {
|
||||
int nSyncHeight = -1;
|
||||
|
||||
Reference in New Issue
Block a user