Defeating Rogue DHCP Servers with DHCP Snooping
DHCP Snooping is a Layer 2 security feature that prevents rogue DHCP servers by categorizing switch ports as 'trusted' or 'untrusted' for DHCP traffic.
The Rogue DHCP Server Threat
In a standard network, clients broadcast DHCP Discover messages to find an IP address. If an attacker connects a **Rogue DHCP server** to the network, it can respond faster than the legitimate server, assigning clients invalid IP addresses or a malicious default gateway, leading to a Man-in-the-Middle (MitM) attack.
How DHCP Snooping Works
**DHCP Snooping** acts like a firewall between untrusted hosts and trusted DHCP servers. It validates DHCP messages received from untrusted sources and filters out invalid messages.
* **Trusted Ports:** Connect to legitimate DHCP servers or uplink switches. DHCP Offer/Ack messages are allowed. * **Untrusted Ports:** Connect to end-user devices. DHCP Offer/Ack messages received here are dropped.
The DHCP Snooping Binding Database
As DHCP Snooping monitors legitimate DHCP transactions, it builds a **binding database**. This database maps a client's MAC address, leased IP address, lease time, binding type, VLAN number, and the interface connected to the switch. This database is later used by other security features like Dynamic ARP Inspection (DAI) and IP Source Guard.
❓ Frequently Asked Questions
What is the purpose of DHCP Snooping?
It prevents rogue DHCP servers from assigning invalid IP parameters to clients on the network.
What is a trusted port in DHCP Snooping?
A trusted port is explicitly configured to allow DHCP server responses (Offers and Acknowledgments), usually facing the real DHCP server.
What information is stored in the DHCP Snooping binding table?
It stores MAC addresses, leased IP addresses, lease times, VLANs, and interface IDs for legitimate clients.