How to do it...

In the previous diagram, trigger a DNS query from the client to the name server and capture the DNS query packet for record type analysis. The DNS query can be triggered from the client using different mechanisms, which may vary depending on the configuration, software version, vendor platform, and so on of the client. The following are few examples that we could use to trigger the query from the client:

  • Open a web browser on the client and type a URL, such as www.packtpub.com.
  • Open a terminal and trigger a ping to a known domain name. In Ubuntu and other Linux distributions, ping xyz.com will trigger a DNS query to resolve an IPv4 address while ping6 xyz.com will trigger a DNS query to resolve an IPv6 address of the domain.
  • Use a tool such as dig, a CLI-based tool that can be used to trigger a DNS query for different types of DNS records.
Figure 13.2: DNS query

The preceding screenshot is a sample capture of a DNS query that was triggered for an AAAA record type. The query type will be set to DNS standard query. Any query must carry the domain name for which the record should be resolved and the type of record requested.

Figure 13.3: DNS response

The preceding screenshot is the sample capture of the DNS response for the query in Figure 13.2. For ease of analysis, Wireshark highlights the packet number of the DNS query in the DNS response packet. The preceding is the response that carries AAAA record response for the domain name that was requested by the client.

For each DNS query requesting any record type, there must be a response for the respective record from the server. If we don't see any such response or get a negative response, it indicates some issue that needs additional analysis. For example, a missing record in the server database for the queried record type might result in responding with an error message.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.36.141