NetworksDNS
DNS — Domain Name System
The phonebook of the internet — translates domain names to IP addresses.
DNS Resolution Process
1
Browser Cache
Check local cache first
2
OS Resolver
Query OS DNS cache
3
Recursive Resolver
ISP/Public DNS server
4
Root/TLD/Authoritative
Walk DNS hierarchy
5
Return IP
IP address resolved
DNS Record Types
| Record | Purpose | Example |
|---|---|---|
| A | Maps domain to IPv4 address | 142.250.80.46 |
| AAAA | Maps domain to IPv6 address | 2607:f8b0::... |
| CNAME | Canonical name — domain alias | www → example.com |
| MX | Mail exchange — email server | mail.google.com |
| NS | Name server — DNS authority | ns1.google.com |
| TXT | Text records (SPF, DKIM, verification) | v=spf1 include:_spf... |
| SOA | Start of Authority — zone info | Primary NS, admin email |
Common DNS Concepts
TTL (Time To Live)
How long a DNS record is cached before refreshing. Lower TTL = faster updates but more queries.
Recursive vs Iterative
Recursive resolver handles the full lookup chain. Iterative queries go step by step through the hierarchy.
DNS Caching
Browsers, OS, and ISPs cache DNS results to speed up repeat queries and reduce network load.
DNS Security (DNSSEC)
Adds cryptographic signatures to DNS records to prevent spoofing and cache poisoning attacks.