Network Security · Topic 3 of 8

DHCP Snooping, Dynamic ARP Inspection and Storm Control

Configure DHCP snooping, Dynamic ARP Inspection and storm control on IOS XE switches to stop rogue DHCP servers, ARP spoofing and broadcast storms.

  • 5 min
In a nutshell
  • DHCP snooping drops server messages arriving on untrusted ports.
  • The snooping binding table lists MAC, IP, VLAN, port and lease.
  • DAI checks ARP packets against the binding table and needs snooping.

What it is

DHCP snooping, Dynamic ARP Inspection and storm control protect the address and traffic services that every Layer 2 network depends on.

DHCP and ARP have no authentication, so any host can answer. An attacker can hand out false settings, or lie about which MAC address owns an IP. These features let the switch decide which ports and which messages to believe.

Clientsends DHCP requestarrives atSwitchDHCP snoopingforwards only fromTrusted portreal DHCP serverRogue serveruntrusted portoffer dropped bySwitchDHCP snooping

How it works

Each feature builds on trusted and untrusted ports, and the first feeds the second.

DHCP snooping

DHCP snooping classifies ports as trusted or untrusted. Trusted ports lead to the real DHCP server, such as uplinks. Server messages, such as offers and acknowledgements, are dropped if they arrive on an untrusted port, which stops a rogue DHCP server.

The switch also builds a binding table. Each entry links a MAC address, an IP address, a VLAN, a port and a lease time.

Switch(config)# ip dhcp snooping
Switch(config)# ip dhcp snooping vlan 10,20
Switch(config)# interface GigabitEthernet0/24
Switch(config-if)# ip dhcp snooping trust
Switch(config)# interface GigabitEthernet0/5
Switch(config-if)# ip dhcp snooping limit rate 15
Switch# show ip dhcp snooping
Switch# show ip dhcp snooping binding

The rate limit protects against DHCP starvation, where an attacker sends many requests with spoofed MAC addresses to exhaust the pool. Port security also helps, because it limits the MAC addresses per port. If a port exceeds the rate, it is err disabled.

Dynamic ARP Inspection

ARP spoofing sends false ARP replies, so that victims send traffic to the attacker. This is the basis of a man-in-the-middle attack on a local subnet. Dynamic ARP Inspection (DAI) checks ARP packets on untrusted ports against the DHCP snooping binding table.

An ARP packet that does not match a known binding is dropped. Trusted ports, such as uplinks to other switches, are not checked.

Switch(config)# ip arp inspection vlan 10,20
Switch(config)# ip arp inspection validate src-mac dst-mac ip
Switch(config)# interface GigabitEthernet0/24
Switch(config-if)# ip arp inspection trust
Switch(config)# interface GigabitEthernet0/5
Switch(config-if)# ip arp inspection limit rate 15
Switch# show ip arp inspection
Switch# show ip arp inspection statistics

The validate options add extra checks, such as that the source MAC in the Ethernet header matches the sender MAC in the ARP body. A host with a static IP address has no binding, so it needs an ARP access list.

Switch(config)# arp access-list STATIC-HOSTS
Switch(config-arp-nacl)# permit ip host 10.1.10.5 mac host 0011.2233.4455
Switch(config)# ip arp inspection filter STATIC-HOSTS vlan 10

Storm control

A storm is a flood of broadcast, multicast or unicast traffic that uses bandwidth and CPU. It may come from a loop, a faulty network card or an attack. Storm control measures traffic on a port over time and acts when it passes a threshold.

Switch(config)# interface GigabitEthernet0/5
Switch(config-if)# storm-control broadcast level 20
Switch(config-if)# storm-control multicast level 30
Switch(config-if)# storm-control action shutdown
Switch# show storm-control

The level is a percentage of the port bandwidth. The action can be to drop the excess traffic, to send an SNMP trap, or to shut the port down.

How the three work together

AttackDefence
Rogue DHCP serverDHCP snooping trusted ports
DHCP starvationSnooping rate limit and port security
ARP spoofingDynamic ARP Inspection using the binding table
Broadcast stormStorm control

Enable snooping first, because DAI needs its bindings.

What to remember for the exam

Seven facts cover most questions on this topic.

  • DHCP snooping drops server messages arriving on untrusted ports.
  • The snooping binding table lists MAC, IP, VLAN, port and lease.
  • DAI checks ARP packets against the binding table and needs snooping.
  • Trust uplinks and the DHCP server port. Leave access ports untrusted.
  • A rate limit on untrusted ports defends against starvation and ARP floods.
  • Static IP hosts need an ARP access list for DAI.
  • Storm control uses a percentage threshold, and the action can be to shut down the port.
Exam tip

When a question says a client got a wrong gateway from an unknown server, think of a rogue DHCP server and DHCP snooping.

Common mistakes

These four mistakes appear often.

Forgetting to enable snooping on the VLAN. The ip dhcp snooping command alone does not protect a VLAN until you add ip dhcp snooping vlan.

Not trusting the uplink. Legitimate DHCP replies are dropped, and clients cannot get addresses.

Enabling DAI without bindings. Static hosts lose connectivity unless an ARP access list permits them.

Setting storm control too low. Normal bursts then trigger the action and cause outages.

Watch out

Make sure the trusted port really faces the legitimate DHCP server path. Trusting the wrong port defeats the protection.

Check yourself

Work through these three questions.

  • What does DAI compare an ARP packet against?

    It compares the packet with the DHCP snooping binding table, and drops those that do not match.

  • Which ports should be trusted in DHCP snooping?

    Ports that lead towards the legitimate DHCP server, such as uplinks, while access ports stay untrusted.

  • How can a host with a static IP address pass DAI?

    Permit it in an ARP access list and apply it with ip arp inspection filter, since it has no snooping binding.

Topic 3 of 8 in Network Security

Test yourself on Network Security

The full Cisco CCNP 350-701 SCOR question bank has 822 questions, with timed practice exams and an explanation for every answer.

This study guide is independent and is not affiliated with, endorsed by, or sponsored by Cisco. Vendor names, certification names and exam codes are trademarks of their respective owners and are used for identification only.