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

IPv6 Nodes #84

Closed
juliaszone opened this issue Aug 13, 2024 · 8 comments
Closed

IPv6 Nodes #84

juliaszone opened this issue Aug 13, 2024 · 8 comments
Assignees
Labels
enhancement New feature or request

Comments

@juliaszone
Copy link

Hi, I run 2 IPv6 enabled nodes and I saw that only IPv4 is supported by the website.
Are there any plans for IPv6 support?

@juliaszone
Copy link
Author

juliaszone commented Aug 13, 2024

My idea for showing IP addresses in the list would then be to show the IPv6, then IPv4 ontop of each other, instead of only IPv4. Or even better, just remove it.
For nodes submitted using IP addresses, it shows up twice.
Clients usually try IPv6, then fall back to IPv4 when connecting to a domain. If people only use IPv4 addresses instead of domain names, this cannot happen.
NAT64 clients also have it easier, because it works better on those networks thanks to DNS64. The application would need to be aware of NAT64 networks by querying for ipv4only.arpa IN AAAA, which I believe not many do.
I guess they can still show up in the node info tab, with all IPv6 and then all IPv4 addresses listed.

@juliaszone
Copy link
Author

If IPv6 support is added, I believe it would also be nice to be able to filter for IPv6/IPv4/Dualstack nodes...

@ditatompel ditatompel self-assigned this Aug 15, 2024
@ditatompel ditatompel added the enhancement New feature or request label Aug 15, 2024
@ditatompel
Copy link
Owner

Thank you for the advice. I will try to implement that.

However, it doesn't look like it will happen anytime soon because most of the "probers" I have don't have (or explicitly disable) IPv6.

My estimate is that it will take around 1 to 2 months before we can implement and carry out testing.

ditatompel added a commit that referenced this issue Sep 5, 2024
This commit accept IPv6 nodes submission.

When user submit new public node, the server will check IP addresses
from given hostname. If host IP addresses doesn't have IPv4, it will
be recorded as "IPv6 only" node.

Probers that support IPv6 may add `IPV6_CAPABLE=true` to the `.env`
file.

Please note that this feature still experimental and may not being
merged to the main branch.
@ditatompel
Copy link
Owner

Hi @juliaszone , I've change the code to accept IPv6 node and enabling IPv6 on one of the probers (linode). Can you please try add your nodes to see how it goes?

@juliaszone
Copy link
Author

juliaszone commented Sep 8, 2024

Hi @juliaszone , I've change the code to accept IPv6 node and enabling IPv6 on one of the probers (linode). Can you please try add your nodes to see how it goes?

I tried to add it by domain, but it says it already exists. Those still show up as an IPv4 despite being dual stack.

I would show IPv6 then IPv4 address in the list like so (edited in browser devtools):
image
And now if a node has no IPv4:
image
same for if a node has no IPv6:
image
I would also apply it exactly like that to the "Public IP" field in the "Probe Logs". The code could be reused easily.
For nodes that have been added using an IP address, I'd propose a removal of the "Public IP" fields in the list and on the logs.
image
image

I have tried adding IPv6 addresses, and it worked. They can be removed now.
https://xmr.ditatompel.com/remote-nodes/logs/?node_id=272
https://xmr.ditatompel.com/remote-nodes/logs/?node_id=273
A problem: IPv6 addresses when in URL/Port notation are to be put in square brackets:
image
So, correct it would be [2a02:810d:b5bf:ece0::1:180]:18089. It happens on the list and in the logs.

A nice feature for dualstack nodes would be to crawl it on IPv4 and IPv6. If either is broken, then display it like this:
image

@juliaszone
Copy link
Author

juliaszone commented Sep 8, 2024

After some downtime of my nodes, they showed up as IPv6. Then now, it changed back to IPv4 for one node.
image

ditatompel added a commit that referenced this issue Sep 9, 2024
This commit add IsIPv6Only function inside `internal/ip` package
and moving `geo` package from `internal/geo` to `internal/ip/geo`.

Although it increases server resource usage, checking hostname to IP is
required every time the prober sends a report so that the `ipv6_only`
record in the database is not up-to-date. Previously, this feature did
not exist.
ditatompel added a commit that referenced this issue Sep 9, 2024
Wraps IPv6 host in square brackets, returns as-is for domain names
or IPv4 addresses.
@ditatompel
Copy link
Owner

they showed up as IPv6. Then now, it changed back to IPv4 for one node.

If you have more than one A and/or AAAA DNS record, the current cycle and the next cycle may display different IP address. It depends on the first IP address obtained from the hostname lookup.

Therefore, I removed the IP address information from the table (but still exists from API call result) and replaced it with information about whether the host only supports IPv6 or not (61cc98e). So, if the submitted node is IPv6 address (or domain name that doesn't have IPv4) it will show IPV6 only info.

Speaking of IP addresses, maybe I could add an "IP lookup" button or something like that so that visitors can get that information only when needed. But I can't promise that it will be available anytime soon.

A nice feature for dualstack nodes would be to crawl it on IPv4 and IPv6.

I wouldn't implement something like that. Performing RPC calls for every A/AAAA record for each node would take many times more resources than it needs to.

I have tried adding IPv6 addresses, and it worked. They can be removed now.
https://xmr.ditatompel.com/remote-nodes/logs/?node_id=272
https://xmr.ditatompel.com/remote-nodes/logs/?node_id=273

Sure, will do. Thanks for your help!

@ditatompel
Copy link
Owner

I think you're right Julia. For some reason, I need to shows IP addresses of each nodes. ( issue #105 )

ditatompel added a commit that referenced this issue Sep 11, 2024
For future use investigations about "suspicious" nodes. #105
ditatompel added a commit that referenced this issue Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants