Why does a call to IPInterfaceProperties::DnsAddresses return three DNS servers?

156 views Asked by At

I have some code running on a Windows XP Embedded machine which attempts to record the current network settings using a snippet along the following lines:

array<NetworkInterface^>^ ifs = NetworkInterface::GetAllNetworkInterfaces();
for each (NetworkInterface^ nic in ifs)
{
    IPInterfaceProperties^ properties = nic->GetIPProperties();
    for each( IPAddress^ ipaddress in properties->DnsAddresses)
    {
        Console::WriteLine(String::Format("{0}", ipaddress));
    }
}

The machine has two static DNS servers set (8.8.8.8 and 8.8.8.4) so why does the code above print out:

fec0:0:0:ffff::1%1
8.8.8.8
8.8.4.4

Where does that first line come from? ..and why doesn't it appear if I run the same code on a Windows 7 machine?

1

There are 1 answers

1
Anthony Kiskaden On

Looks like a default IPv6 DNS address. I'm not sure why it wouldn't show up in Windows 7 but I guess it depends on your DNS settings.