network interface names

René Berber r.berber@computer.org
Fri Apr 21 22:41:00 GMT 2006


Ian wrote:

> How does cygwin's eth(whatever) relate to the windows interface names?
> 
> For example, on my laptop, eth0 is tied to my wireless network
> connection and eth1 is tied to my wired local area connection.
> 
> I'm developing DHCP software for cygwin, and I need to be able to derive
> the cygwin network interface name (e.g. eth0, or eth1...) given either
> the connection's MAC address, its IP address, or its windows interface
> name (e.g. "Local Area Connection", or "Gigabit Integrated Controller",
> or "WLAN Mini-PCI Card #2", or something like).

I don't know the answer, but I would like to know how did you determine that
eth0 (is it /dev/eth0?) is the wireless, etc.

What I have used comes with WinPCAP, with WpdPack there are several examples, in
Examples-pcap/iflist the resulting program lists your network interfaces, as this:

\Device\NPF_{9E387891-E631-4411-B604-0DE577B8EA67}
        Description: Intel(R) PRO/1000 MT Desktop Adapter (Microsoft's Packet
Scheduler)
        Loopback: no
        Address Family: #2
        Address Family Name: AF_INET
        Address: 192.168.10.2
        Netmask: 255.255.255.0
        Broadcast Address: 255.255.255.255

As you can see, there is no MAC address, or info about the address being set by
DHCP, but that probably could be obtained.  My question above is because I would
prefer to use /dev/eth1 that "\Device\NPF_...".
-- 
René Berber


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list