Enumerating Network Adapters

Olivier Parisy olivier.parisy at free.fr
Sun Aug 29 12:31:57 CEST 2004


Hi all,

I'd like to get, in a portable way, a list of all
network adapters on a local machine running some
python code.

socket.gethostname() does not seem enough, as it
only returns one name ; I'd like to get all
available IPs.

I could process ipconfig or ifconfig outputs, but
this is OS-dependant and not very future-proof...

Best regards,
Olivier Parisy.




More information about the Python-list mailing list