aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPieter Wuille <pieter@wuille.net>2021-07-15 12:59:23 -0700
committerPieter Wuille <pieter@wuille.net>2021-08-05 09:40:04 -0700
commit8df3e5bd84f2b2b60730034cbd71fe8f3276d434 (patch)
treee2901928c6dc6cb050400455c843710297c75fa8
parent83dfe6c65ef6c30ca01348ee5059c3d76e03d1d3 (diff)
downloadbitcoin-8df3e5bd84f2b2b60730034cbd71fe8f3276d434.tar.xz
Randomize the order of addr processing
Github-Pull: #22387 Rebased-From: 5648138f5949013331c017c740646e2f4013bc24
-rw-r--r--src/net_processing.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/net_processing.cpp b/src/net_processing.cpp
index 019d00e7d6..7ca8c10d85 100644
--- a/src/net_processing.cpp
+++ b/src/net_processing.cpp
@@ -2619,6 +2619,7 @@ void PeerManager::ProcessMessage(CNode& pfrom, const std::string& msg_type, CDat
peer->m_addr_token_timestamp = current_time;
const bool rate_limited = !pfrom.HasPermission(NetPermissionFlags::PF_ADDR);
+ Shuffle(vAddr.begin(), vAddr.end(), FastRandomContext());
for (CAddress& addr : vAddr)
{
if (interruptMsgProc)