Overview
This lecture introduces the Domain Name System (DNS), explains its hierarchical structure, and details various DNS resource records, including their purposes and configurations.
Introduction to DNS
- DNS stands for Domain Name System, translating domain names into IP addresses to facilitate network communication.
- DNS is a distributed, hierarchical database with parts stored on multiple servers worldwide.
- The database structure starts with 13 root server clusters, extending to top-level domains (TLDs) like .com or country codes (.us, .ca).
- Domains can be further subdivided (e.g., www.professormesser.com, mail.professormesser.com).
DNS Query Tools
- The
dig command (Linux/Mac) and nslookup (Windows) retrieve DNS record information for specific domains.
- These tools display resource records like IP addresses, mail servers, and text records.
DNS Resource Records
- Resource Records (RR) are entries in the DNS database storing key details such as IP addresses, certificates, or aliases.
Address Records
- A records map hostnames to IPv4 addresses; AAAA (quad A) records map to IPv6 addresses.
- Records specify a time to live (TTL), controlling how long clients cache results.
Canonical Name (CNAME) Records
- CNAME records allow multiple names to point to the same server, simplifying administration.
Mail Exchanger (MX) Records
- MX records define the mail servers responsible for receiving email for a domain.
- Email delivery checks the MX record to determine the proper mail server, then looks up that server's address.
Text (TXT) Records
- TXT records store arbitrary, human-readable text, often for verification and authentication.
- Examples include verification for services and email anti-spam controls.
DNS and Email Security
- DKIM (DomainKeys Identified Mail): Uses DNS TXT records to publish public keys, enabling digital signatures for email authenticity.
- SPF (Sender Policy Framework): Lists authorized mail servers in DNS TXT records, helping prevent spoofed emails.
- DMARC (Domain-based Message Authentication Reporting and Conformance): TXT records define how to handle emails failing SPF/DKIM and provide reporting options.
Key Terms & Definitions
- DNS — System translating domain names to IP addresses.
- A Record — Maps hostname to IPv4 address.
- AAAA Record — Maps hostname to IPv6 address.
- CNAME Record — Alias pointing one name to another.
- MX Record — Identifies mail servers for a domain.
- TXT Record — Stores text information for various uses.
- DKIM — Method using DNS to verify email authenticity via digital signatures.
- SPF — Lists allowed email senders for a domain.
- DMARC — Policy for handling email authentication failures.
Action Items / Next Steps
- Practice using
dig and nslookup to query DNS records.
- Review configuration options for A, MX, CNAME, and TXT records.
- Read about SPF, DKIM, and DMARC setup for securing email domains.