[Replicant] [PATCH v2] Fix "RepWifi connection not correctly reported to userspace apps" Issue #1792.
Joonas Kylmälä
joonas.kylmala at iki.fi
Mon Aug 7 19:13:00 UTC 2017
Fil:
> It does matter, instead.
> While IPv6 addresses are usually assigned in a globally-unique way,
> that's not the case with IPv4, where most infrastructures heavily rely
> on NAT'ing, hence giving devices behind a router/AP a private address
> (i.e. 192.168.x.x or 10.x.x.x).
Think about the 1% who do not use NAT (actually in Finland the ISPs give
usually 5 IPv4 addresses so it might not be too uncommon). You mentioned
earlier the link local addresses so we could make a list of similar
non-working IPv4 addresses (in case there are others) and then check if
the address belongs to that list and act accordingly. The function
isLinkLocalAddress() can be used.
I also thought about making a list of valid IP addresses, i.e., site
local addresses + public ip addresses but how do we know what is public
ip address? The java.net.InetAddress class didn't have any methods for
that so implementing it in this way doesn't sound very promising.
What are your thoughts on this?
Joonas
More information about the Replicant
mailing list