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

Don't send invalid IP addresses in info messages #81

Merged
merged 1 commit into from
Jan 15, 2019

Conversation

metalicjames
Copy link
Member

@metalicjames metalicjames commented Jan 15, 2019

Sometimes nodes get connected to themselves, or are unable to resolve IP addresses. In that case an IP address such as 127.0.0.1 or 0.0.0.0 might be sent, which will cause the remote peer to disconnect. Add a check for such IP addresses before adding them to the peers list to send with an info message. Also improved the log message for disconnecting a peer behaving in this way to display the offending malformed IP address.

Sometimes nodes get connected to themselves, or are unable to resolve IP addresses. In that case and IP address such as 127.0.0.1 or 0.0.0.0 might be sent, which will cause the remote peer to disconnect. Add a check for such IP addresses before adding them to the peers list to send with an info message. Also improved the log message for disconnecting a peer behaving in this way to display the offending malformed IP address.
@metalicjames metalicjames merged commit 9ede1d8 into mit-dci:master Jan 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant