p2p: Allow whitelisting outgoing connections #27114 #20
Replies: 1 comment
-
SummaryBy default, a Bitcoin Core node allows up to 125 connections (8 of which are outbound) to other peers. Whitelist is a startup -whitelist option that allows to add extra permission flags to the peers connecting from the given IP address or CIDR-notated network. It uses the same permissions as -whitebind: bloomfilter, noban, forcerelay, relay, mempool, download, addr). Previously whitelisting was only allowed for inbound peers, and this PR proposes and adds whitelisting for outbound peers too. QuestionsWhat does this PR do?This PR proposes to add a new field in the What are
|
Beta Was this translation helpful? Give feedback.
-
Session Details
[Net]
[python][c++]
Notes
By default, a Bitcoin Core node allows up to 125 connections (8 of which are outbound) to other peers. Whitelist is a startup option that allows to add permission flags to the peers connecting from the given IP address or CIDR-notated network. It uses the same permissions as -whitebind: bloomfilter, noban, forcerelay, relay, mempool, download, addr).
The intent for whitelisting a peer is to give a trusted peer special permissions(like- not ever banning that peer, bloom filters etc..). we can currently whitelist inbound peers.
References
This PR is a sub PR of : https://bitcoincore.reviews/26441
Questions
Did you review the PR? Concept ACK, approach ACK, tested ACK, or NACK? What was your review approach?
What does this PR do?
What are NetPermissionFlags? How is it set? When do we set NetPermissionFlags::Implicit?
What does InitializePermissionFlags() function achieve?
whitelist only allows to add permission flags to inbound peers. Why only for inbound ones? Does it make sense to extend the permissions to outbound peers? Why?
ConnectionDirection can be Both, In, Out or None. What does Both mean? What happens in TryParsePermissionFlags if it is None? In which scenarios can this happen?
Learning
Beta Was this translation helpful? Give feedback.
All reactions