I want to find the IP addresses of all network interfaces in an elisp program. I tried this:
(mapcar
(lambda (if)
(cons (car if) (network-interface-info (car if))))
(network-interface-list))
However, when a network interface has both an IPv4 and an IPv6 address, the above only lists the IPv4 address. Is there a way to access the IPv6 address from elisp? (I'd rather avoid parsing the output of ifconfig
.)