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

Allow specifying local ip. And use any by default instead of loopback. #5635

Merged
merged 4 commits into from
May 3, 2023

Conversation

asdacap
Copy link
Contributor

@asdacap asdacap commented May 2, 2023

Fixes #5565

  • Fix local ip not used to configure tcp listener.
  • When resolving local ip, if not specified, use any ip instead of loopback.

Types of changes

What types of changes does your code introduce?

  • Bugfix (a non-breaking change that fixes an issue)

Testing

Requires testing

  • Yes
  • No

If yes, did you write tests?

  • Yes
  • No

Notes on testing

  • Tested with nc command as in the issue. Seems to work.
  • I'm getting incoming connection when not specifying any ip or specifying my correct local ip.
  • posdao test passed, sync hive test passed.

@asdacap asdacap marked this pull request as ready for review May 2, 2023 10:54
@benaadams
Copy link
Member

Not sure about Any by default; loopback means its closed to the Internet whereas Any would open it up by default?

@asdacap
Copy link
Contributor Author

asdacap commented May 3, 2023

Well... yea. Thats the point. Thats the default behaviour of go's net package, and therefore geth. Thats actually what we are currently using for TCP server, since we don't specify local ip before this.

Copy link
Member

@benaadams benaadams left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And any exciting JsonRpc's need to use .JwtSecretFile?

@asdacap
Copy link
Contributor Author

asdacap commented May 3, 2023

Not sure what you mean by that.

@asdacap asdacap merged commit 1c03616 into master May 3, 2023
@asdacap asdacap deleted the fix/set-local-ip branch May 3, 2023 06:08
asdacap added a commit that referenced this pull request Aug 24, 2023
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.

Not listening to 30303 on IPv6
2 participants