so I've set up a dual stack network at home now and noticed that HA doesn't properly recognize the GUA addresses as local, because it currently just checks against a static list of private addresses which for IPv6 include the ULA + link local ranges.
That leads to users that have "login from local only" enabled being locked out (and there will be other things, e.g. webhook check that as well).
To fix that, the correct way would be (IMO) to change the helper to also include your local IPv6 by calculating that range from your GUA + prefix.
However, to do that would mean to make the is_local aware of your network, which means I'd need to inject the hass object everywhere that is being used.
Before I go down that rabbit hole: Opinions? Did I miss something?
#IPv6 GUA addresses
1 messages · Page 1 of 1 (latest)
I think if you have a more complicated network setup, calculating the subnet might not work, a number of ISPs hand out a /5x for your local devices which the router would normally dish out to its internal network(s) as /64s. You might have HA on one /64, while the clients are on another /64.
Do we need to inject hass to get networking information as you can grab it all using socket? Or perhaps a helper function to collect all networking information which can be reused wherever within HA?
Yes, exactly what happened on my end, but you could manually override the prefix