Michael C. Toren on Thu, 20 Dec 2001 18:03:13 -0500


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] how to iterate through all of the IP addresses on a box?

  • From: "Michael C. Toren" <mct@netaxs.com>
  • To: plug@lists.phillylinux.org
  • Subject: Re: [PLUG] how to iterate through all of the IP addresses on a box?
  • Date: Thu, 20 Dec 2001 18:03:13 -0500
  • User-agent: Mutt/1.2.5i

> I realize that there might not be a portable way to do this, but I
> still need to be able to do it.  And I don't have a copy of my Sevens'
> book handy.
> 
> Anyone know how or have any pointers to where I might be able to find out?

I had a hell of a time figuring out how to query the local
interfaces list portably, but you can see what I finally came
up with in tcptraceroute-1.3beta[1] for the getinterfaces()
function.  Be warned, though, the code is far from elegant...

-mct

[1] http://michael.toren.net/code/tcptraceroute/beta/