File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -1633,6 +1633,11 @@ void CConnman::ThreadOpenConnections()
16331633 LOCK (cs_vNodes);
16341634 BOOST_FOREACH (CNode* pnode, vNodes) {
16351635 if (!pnode->fInbound && !pnode->fAddnode ) {
1636+ // Netgroups for inbound and addnode peers are not excluded because our goal here
1637+ // is to not use multiple of our limited outbound slots on a single netgroup
1638+ // but inbound and addnode peers do not use our outbound slots. Inbound peers
1639+ // also have the added issue that they're attacker controlled and could be used
1640+ // to prevent us from connecting to particular hosts if we used them here.
16361641 setConnected.insert (pnode->addr .GetGroup ());
16371642 nOutbound++;
16381643 }
Original file line number Diff line number Diff line change @@ -92,6 +92,7 @@ UniValue getpeerinfo(const JSONRPCRequest& request)
9292 " \" version\" : v, (numeric) The peer version, such as 7001\n "
9393 " \" subver\" : \" /Satoshi:0.8.5/\" , (string) The string version\n "
9494 " \" inbound\" : true|false, (boolean) Inbound (true) or Outbound (false)\n "
95+ " \" addnode\" : true|false, (boolean) Whether connection was due to addnode and is using an addnode slot\n "
9596 " \" startingheight\" : n, (numeric) The starting height (block) of the peer\n "
9697 " \" banscore\" : n, (numeric) The ban score\n "
9798 " \" synced_headers\" : n, (numeric) The last header we have in common with this peer\n "
You can’t perform that action at this time.
0 commit comments