Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(p2p): consistent checks before connecting #592

Merged
merged 1 commit into from
Oct 23, 2018

Conversation

sangaman
Copy link
Collaborator

This commit fixes the logic that prevents us from connecting to banned nodes or creating duplicate connections to any node. Some of that logic was only applied for connecting to a set of nodes, but not on attempts to connect to a single node like through the rpc connect call. All general checks have been moved to the addOutbound` method which is a key method that all outgoing peer connection attempts go through.

This commit fixes the logic that prevents us from connecting to banned
nodes or creating duplicate connections to any node. Some of that logic
was only applied for connecting to a set of nodes, but not on attempts
to connect to a single node like through the rpc `connect call. All
general checks have been moved to the `addOutbound` method which is a
key method that all outgoing peer connection attempts go through.
@sangaman sangaman added bug Something isn't working p2p Peer to peer networking labels Oct 18, 2018
@ghost ghost assigned sangaman Oct 18, 2018
@ghost ghost added the in progress label Oct 18, 2018
@sangaman sangaman merged commit aad14e2 into master Oct 23, 2018
@ghost ghost removed the in progress label Oct 23, 2018
@sangaman sangaman deleted the p2p/connection-checks branch October 23, 2018 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working p2p Peer to peer networking
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants