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

Advertisment converting ipv4 into ipv6 #290

Open
danthegoodman1 opened this issue Nov 19, 2020 · 0 comments
Open

Advertisment converting ipv4 into ipv6 #290

danthegoodman1 opened this issue Nov 19, 2020 · 0 comments

Comments

@danthegoodman1
Copy link

danthegoodman1 commented Nov 19, 2020

with the code noise.NewNode(noise.WithNodeBindHost(netIP), noise.WithNodeBindPort(uint16(*NodePort))), when a message is sent to something using the ipv4 address 192.168.0.4 it works fine. However when I go back through kademlia table:
for _, node := range overlay.Table().Peers() {
log.Println(node)
log.Println(node.Host)
}
I get addresses like "address": "[c0a8:1c1::]:4444" and a host of c0a8:1c1::.

How do I prevent it from converting into an IPv6 address?

Edit: I'll also add that the node knows the IPv4 itself: log.Println("Node listening on:", TestNode.Addr()) -> Node listening on: 192.168.1.193:4444

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

No branches or pull requests

1 participant