Host Name Resolution for Dual Stack (IPv4/IPv6) (Windows Embedded CE 6.0)
1/6/2010
Windows Embedded CE resolves host names into IPv6 addresses via queries to a DNS or WINS server, or via IPv6 link local multicast. DNS AAAA and A queries can be performed over either IPv4 or IPv6. WINS queries are only for IPv4 addresses and are only performed over IPv4.
To use a host name as an alias for an IPv6 address, you must ensure that the name is unique and that it resolves to the correct IPv6 address. For IPv6 name-to-address entries, the IPv6 address is written by using standard colon-hexadecimal format. For more information, see IPv6 Addresses.
When using the getaddrinfo function, dual stack name resolution occurs. Domain names are resolved by sending DNS name queries to a configured DNS server. This is a computer that either stores domain name-to-IPv6 address mapping records or has records of other DNS servers. The DNS name resolution may yield both IPv4 and IPv6 addresses.
The DNS server resolves the queried domain name to an IPv4 or IPv6 address and returns the results. When configured for DHCP, the DHCP server provides IPv4 addresses of DNS and WINS servers used for both A and AAAA searches.
The DNS client in Windows CE .NET 4.1 and later also supports the processing of AAAA (quad-A) resource records. The Internet Protocol (TCP/IP)must be configured with the IPv4 address of a DNS server.
The Host name is resolved to an address by a DNS, WINS, or Link Local Multicast Name Resolution (LLMNR) resolver. The following table shows each resolver mode.
Resolver mode | Description |
---|---|
DNS |
The host name in an A record (32-bit IPv4 address) or AAAA record (128-bit IPv6 address) is resolved by a DNS server. The following list shows the resolving order:
|
LLMNR |
Link Local Multicast Name Resolution (LLMNR) is a peer-to-peer name resolution protocol that is used for IPv6 when DNS name resolution is not possible. LLMNR operates only on the local link. It uses the DNS packet format and supports DNS formats, types, and classes. For information about the address and port used for LLMNR queries, see TCP/IPv6 Configurable Registry Settings. |
WINS |
The host name in an A record (32-bit IPv4 address) is resolved by a WINS server. The following list shows the resolving order:
Note:
The WINS resolver mode is not used for AAAA searches.
|
Using registry entries, you can specify the order in which addresses are resolved.
The following table shows the registry values for controlling the global resolver modes. The registry key HKEY_LOCAL_MACHINE\Comm\AFD contains these values.
Value | Description |
---|---|
NameResolutionOrdering |
Use this value to specify the order in which addresses are resolved.
The default order for resolving an A record query is DNS, WINS, and then WINS BC. The default order for resolving an AAAA record query is DNS across an IPv4 network, and then LLMNR to link-local Multicast address. |
ResolverCheckCacheFirst |
Default setting is 1 (True). This value can be set either to 0 (False) or 1 (True) to specify whether the cache is checked before the WINS and DNS servers are queried when resolving names. |
UpdateDnsName |
This value is not set by default. It specifies whether a device should attempt to register its DNS name on the network automatically. A value of 1 is assumed when no other value exists. If you do not want the device to attempt to register the name automatically, set this value to 0. If this value is not set to 0, the device attempts to register its DNS name on the network automatically when a new network interface comes up or when an application calls sethostname. |
MaxPositiveCacheTTL |
Use this value to change the maximum length of time, in seconds, that a successfully resolved host name is held in the resolver queue. Applications seeking to resolve a host name use this cached value rather than sending resolver queries onto the communication network interfaces. On a reliable network, raising this value may lower the number of DNS requests. Default value is 600. |
MaxNegativeCacheTTL |
Use this value to change the maximum length of time, in seconds, that an unsuccessfully resolved host name is held in the resolver queue. Applications seeking to resolve a host name use this cached value rather than sending resolver queries onto the communication network interfaces. On a reliable network, raising this value may lower the number of DNS requests. Default value is 30. |
EnableDNS6Addresses |
Not supported. |
EnableSingleLabelDNS |
Use this value to enable sending DNS queries for a single label name:
Typically, the host's domain name is appended to a single label name to form a fully qualified domain name for DNS queries. |
For information about how source and destination addresses are determined, see Default Address Selection for IPv6.
For information about the algorithms used to determine source and destination addresses of appropriate scope and configuration status, thus determining which stack (IPv4 or IPv6) to use, see Default Address Selection for IPv6.
See Also
Tasks
How to Convert an Application from IPv4 to IPv4/IPv6