threefoldtech / tfchain

Threefold Chain.
Apache License 2.0
15 stars 11 forks source link

Allow fe80:: range as a valid ipv6 gateway for public config #911

Open coesensbert opened 11 months ago

coesensbert commented 11 months ago

Description

Upon setting the public config of a node, allow fe80:: range as 'Gateway IPv6'. This can be a valid configuration if the local setup allows it. Example: fe80::1 image

Temporary workaround

ip netns exec public ip -6 route del default via 2a01:4f8:10a:710::1
ip netns exec public ip -6 route add default via fe80::1 dev public
zaelgohary commented 11 months ago

Should be done once https://github.com/threefoldtech/tfgrid-sdk-ts/pull/1154 is merged.

A-Harby commented 10 months ago

I tried adding this configuration a couple of times but kept getting that error.

Validation was passing, but after clicking the save button, the error shows up. image image

A-Harby commented 10 months ago

Blocked on https://github.com/threefoldtech/tfgrid-sdk-ts/issues/1618

coesensbert commented 10 months ago

There is (i believe on-chain?) validation of your added network metrics. Your config from the screenshot can never work. The ip is the same ip as the gateway.

Why you choose to test this specific address? It's already in use. If it's just for testing, make sure to remove those kinds of tests/configs once your done with them.

A-Harby commented 10 months ago

I tried different IPV4 only and it was successful image Then I tried the same with fe80::1 and failed. image

It's probably from chain validation.

A-Harby commented 10 months ago

It appears to be from tfchain public IP validation. image

sameh-farouk commented 4 months ago

I understand that this range is typically used inside an internal network for the router's link-local address and that it is a Valid IPv6 Default Gateway Address as OP stated. I am also aware that these addresses are valid only for communications on a local link (within a subnetwork that a host is connected to) and cannot route on the Internet. So what is being asked here in this ticket conflicted with what was asked before in this one, which implicitly requires a GW address to be a public IP address (It requires the host IP address to be public and the GW address to be In the same subnet as the host IP address). So I can't implement this one without dropping part of what previously asked by @muhamadazmy @muhamadazmy @xmonader can you comment here?

sameh-farouk commented 4 months ago

@delandtj Azamy request your comment. Can you check.