Improve ignore network interface implementation
While checking out the implementation of the configuration option --with-ignored-network-interface-prefix
I noticed several things:
-
IGNORED_IFACE_PREFIX
is ignored for the!HAVE_GETIFADDRS
case - interfaces without the flag
IFF_RUNNING
should be ignored as they aren't active but may have an IP address assigned -
nice_interfaces_is_private_ip()
has no support forAF_INET6
i.e. an IPv6 link-local address will not be detected as private IP - the configuration option
--with-ignored-network-interface-prefix
can only be used once- while this may have been sufficient a few years ago in a VM-only world, nowadays users are likely running more docker/podman containers than VMs
- f.ex. on a machine with active containers you'll see
br-XXX
,dockerX
andvethXXX
interfaces that should be ignored by libnice - one possible implementation approach would be to accept a comma-separated list for this option and update the ignore detection code accordingly