Ethereal-dev: Re: [ethereal-dev] SIOCGIFCONF

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Warren Young <warren@xxxxxxxxxxx>
Date: Wed, 06 Sep 2000 08:37:40 -0600
Guy Harris wrote:
> 
> Some OSes on which it won't work, but on which Ethereal works, come from
> Redmond, Washington, USA; unfortunately, whilst you can implement some
> of "getifaddrs()" on Windows NT by fetching stuff from the registry (you

WSAIoctl(SIO_GET_INTERFACE_LIST) works with Winsock 2.  Depending on the
OS, you get more or less the same info as SIOCGIFCONF.  So much similar,
in fact, that one of my tasks for the FAQ is to write a translator
between the two interfaces for the BSD compatibility item.

That gets you mainly IP addresses, masks, flags and other things.  If
instead you need adapter _names_, you can use GetInterfaceInfo(), part
of the IP Helper API on Windows 98 and Windows 2000.  Or, there's the
harder-to-use GetIfEntry(), which works on those two platforms, and on
WinNT 4 SP4+ as well.

Who says Windows is "unified"?
-- 
= Warren Young, maintainer of the Winsock Programmer's FAQ at:
=     http://www.cyberport.com/~tangent/programming/winsock/
= 
= ICBM Address: 36.8274040 N, 108.0204086 W, alt. 1714m