You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 6, 2023. It is now read-only.
As seen in #17 ifconfig output is platform dependent and we should find a more platform independent way to find all the ip addresses bound to interfaces.
The text was updated successfully, but these errors were encountered:
Python netifaces package can be made used to find the IP address of the all the interfaces.
from netifaces import interfaces, ifaddresses, AF_INET
for ifaceName in interfaces():
addresses = [i['addr'] for i in ifaddresses(ifaceName).setdefault(AF_INET, [{'addr':'No IP addr'}] )]
print '%s: %s' % (ifaceName, ', '.join(addresses))
As seen in #17 ifconfig output is platform dependent and we should find a more platform independent way to find all the ip addresses bound to interfaces.
The text was updated successfully, but these errors were encountered: