ifconfig in python

Mark Wooding mdw at distorted.org.uk
Tue Jan 20 18:41:21 CET 2009

"RasikaSrinivasan at gmail.com" <RasikaSrinivasan at gmail.com> writes:

> one way to get your head around this is - IP Addresses are associated
> with the interface and not the computer. distinction may be subtle but
> critical.

Actually this is wrong for most Unix systems, which use the `weak
end-system model' described in RFC1122.  Weak end-systems accept IP
packets sent to any of the host's addresses (and respond to ARP requests
for any address) arriving on any of its interfaces, and might send a
packet from any of the host's addresses out of any interface.  It's best
to think of the addresses as referring to the host, and not the

That doesn't mean that you can get away with a single address for the
entire host, though: you need addresses which correspond to the networks
you're attached to.

-- [mdw]

More information about the Python-list mailing list