DNS message format

The following illustration describes the DNS message format:

Every DNS message follows that format, although a query would leave the Answer, Authority, and Additional sections blank. A DNS response commonly doesn't use Authority or Additional. We won't concern ourselves with the Authority or Additional sections, as they are not needed for typical DNS queries.

Get Hands-On Network Programming with C now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.