Skip to main content

5. Sample Usage (Example 3)

3. Finally, suppose host M wishes to locate some domain name translation server (either UDP or TCP based) anywhere on the Internet. Furthermore, suppose that host M is on a IP network which does not provide broadcast address capabilities and that host R is a "known" resource location server for that network.

First, since host M prefers to find a domain name server on its own locally connected network if possible, it sends the request

<Does-Anyone-Provide?> <Flags>=<Local-Only>
<Message-ID>=12321 <Resource-List>=
{[TCP, <DOMAIN-NAME-SERVER-PORT>] {M},
[UDP, <DOMAIN-NAME-SERVER-PORT>] {M}}

encoded as the 22 octet message

+-----+-----+-----+-----+
| 3 | 128 | 12321 |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 6 | 2 | 53 | 1 | M |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 17 | 2 | 53 | 1 | M |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+

to host R.

Host R receives the request and consults its tables for any hosts known to support either variety of domain name service. It finds entries indicating that both hosts S and T provide UDP based domain name service but that neither host is on the same IP network as host H. It must then send the negative confirmation reply

<They-Provide> <Flags>=none <Message-ID>=12321
<Resource-List>={}

encoded as the 4 octet message

           +-----+-----+-----+-----+
| 5 | 0 | 12321 |
+-----+-----+-----+-----+

back to host M.

Host M, receiving this reply, might now abandon any hope of finding a server on its own network, reformat its request to permit any host address, and resend

<Does-Anyone-Provide?> <Flags>=none <Message-ID>=12322
<Resource-List>=
{[TCP, <DOMAIN-NAME-SERVER-PORT>] {M},
[UDP, <DOMAIN-NAME-SERVER-PORT>] {M}}

encoded as the 22 octet message

+-----+-----+-----+-----+
| 3 | 0 | 12322 |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 6 | 2 | 53 | 1 | M |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 17 | 2 | 53 | 1 | M |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+

again to host R.

Host R receives this new request and is no longer constrained to return only local addresses. However, since only space for a single qualifying IP address was provided in each request resource specifier, it may not immediately return both addresses. Instead, it is forced to return only the first address and replies

<They-Provide> <Flags>=none <Message-ID>=12322
<Resource-List>={[UDP, <DOMAIN-NAME-SERVER-PORT>] {S}}

encoded as the 13 octet message

   +-----+-----+-----+-----+-----+-----+-----+-----+
| 5 | 0 | 12322 | 17 | 2 | 53 |
+-----+-----+-----+-----+-----+-----+-----+-----+
| 1 | S |
+-----+-----+-----+-----+-----+

to Host M.

Host M receives the reply and (being the suspicious sort) decides to confirm it with host S. It then sends

<Do-You-Provide?> <Flags>=none <Message-ID>=12323
<Resource-List>={[UDP, <DOMAIN-NAME-SERVER-PORT>]}

encoded as the 8 octet message

   +-----+-----+-----+-----+-----+-----+-----+-----+
| 1 | 0 | 12323 | 17 | 2 | 53 |
+-----+-----+-----+-----+-----+-----+-----+-----+

to host S and receives back from host S the reply

<I-Provide> <Flags>=none <Message-ID>=12323
<Resource-List>={}

encoded as the 4 octet message

           +-----+-----+-----+-----+
| 4 | 0 | 12323 |
+-----+-----+-----+-----+

denying any support for UDP based domain name service.

In desperation host M again queries host R, this time excluding host S from consideration, and sends the request

<Does-Anyone-Provide?> <Flags>=none <Message-ID>=12324
<Resource-List>=
{[TCP, <DOMAIN-NAME-SERVER-PORT>] {S},
[UDP, <DOMAIN-NAME-SERVER-PORT>] {S}}

encoded as the 22 octet message

+-----+-----+-----+-----+
| 3 | 0 | 12324 |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 6 | 2 | 53 | 1 | S |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+
| 17 | 2 | 53 | 1 | S |
+-----+-----+-----+-----+-----+-----+-----+-----+-----+

and this time receives the reply

<They-Provide> <Flags>=none <Message-ID>=12324
<Resource-List>={[UDP, <DOMAIN-NAME-SERVER-PORT>] {T}}

encoded as the 13 octet message

   +-----+-----+-----+-----+-----+-----+-----+-----+
| 5 | 0 | 12324 | 17 | 2 | 53 |
+-----+-----+-----+-----+-----+-----+-----+-----+
| 1 | T |
+-----+-----+-----+-----+-----+

from host R which of course host M again insists on confirming by sending the request

<Do-You-Provide?> <Flags>=none <Message-ID>=12325
<Resource-List>=
{[UDP, <DOMAIN-NAME-SERVER-PORT>]}

encoded as the 8 octet message

   +-----+-----+-----+-----+-----+-----+-----+-----+
| 1 | 0 | 12325 | 17 | 2 | 53 |
+-----+-----+-----+-----+-----+-----+-----+-----+

to host T and finally receives confirmation from host T with the reply

<I-Provide> <Flags>=none <Message-ID>=12325
<Resource-List>={[UDP, <DOMAIN-NAME-SERVER-PORT>]}

encoded as the 8 octet message

   +-----+-----+-----+-----+-----+-----+-----+-----+
| 4 | 0 | 12325 | 17 | 2 | 53 |
+-----+-----+-----+-----+-----+-----+-----+-----+

that it indeed provides domain name translation service at UDP port 53.