IPv6 Neighbor Discovery Protocol (NDP)
The protocol that replaces ARP, ICMP redirect and router discovery in IPv6: Neighbor/Router Solicitations and Advertisements, Duplicate Address Detection, and NDP security pitfalls.
1. Executive Summary & Objective
In IPv4 you had a grab-bag of separate mechanisms: ARP for address resolution, DHCP for config, ICMP redirects for better next-hops, and broadcasts everywhere. IPv6 folds all of this into one ICMPv6-based protocol: Neighbor Discovery Protocol (NDP). Understanding its five message types explains almost everything about how IPv6 βjust worksβ on a link β and where it can be attacked.
Objective: Explain the five NDP message types, trace address resolution and DAD step-by-step, and apply the Layer 2 protections (RA Guard, ND inspection) that keep NDP safe.
2. Core Concept & Theory (The βWhyβ)
NDP is carried in ICMPv6 and uses five message types:
| Type | Name | Replaces / purpose |
|---|---|---|
| 133 | Router Solicitation (RS) | βAre there any routers?β |
| 134 | Router Advertisement (RA) | Router announces prefix + flags |
| 135 | Neighbor Solicitation (NS) | ARP request / DAD |
| 136 | Neighbor Advertisement (NA) | ARP reply |
| 137 | Redirect | ICMP redirect (better next-hop) |
The clever efficiency gain over IPv4 ARP is the solicited-node multicast address ff02::1:ffXX:XXXX, built from the low 24 bits of the target address. Instead of broadcasting to every host (IPv4 ARP), an NS is multicast so that typically only the one intended host is interrupted.
3. Architecture & Topology (Visualizing)
Address resolution (the ARP replacement)
Host A needs Host Bβs MAC:
Duplicate Address Detection (DAD)
Before using any address (SLAAC or static), a host checks nobody else has it:
4. Command Execution & Deployment (The βHowβ)
NDP runs automatically, but you inspect and tune it:
show ipv6 neighbors ! the neighbor cache (IPv6 'ARP table')
show ipv6 interface GigabitEthernet0/0 ! ND timers, DAD attempts, RA settings
!
interface GigabitEthernet0/0
ipv6 nd dad attempts 2 ! how many DAD probes before accepting
ipv6 nd ra interval 60 ! how often to send unsolicited RAs
ipv6 nd reachable-time 30000 ! neighbor reachable timer (ms)
Securing NDP at Layer 2
! Block rogue Router Advertisements on an access port
interface GigabitEthernet0/1
ipv6 nd raguard attach-policy HOST_PORTS
!
ipv6 nd raguard policy HOST_PORTS
device-role host
5. Verification & Troubleshooting
show ipv6 neighbors ! STALE/REACH/INCMP states per neighbor
debug ipv6 nd ! live NS/NA/RS/RA exchanges
| Symptom | Cause |
|---|---|
Neighbor stuck INCMP (incomplete) |
NS unanswered β target down or filtered |
| Host loses its address at boot | DAD found a duplicate (check for a static clash) |
| Clients pick the wrong gateway | Rogue RA on the segment β enable RA Guard |
6. Hands-on Lab
Harden an access port against rogue routers and inspect the neighbor cache.
Lab: NDP operations & RA Guard
Create an RA Guard policy for host ports, attach it to an access interface, and verify the neighbor table.
Objectives
- Create an RA Guard policy.
- Declare ports with this policy as host-only (no RAs allowed).
- Select the access port.
- Attach the policy β rogue RAs are now dropped here.
7. Key Takeaways
- NDP = ICMPv6 and replaces ARP, router discovery, and ICMP redirect in one protocol.
- Five messages: RS, RA, NS, NA, Redirect (types 133β137).
- NS uses the solicited-node multicast for efficiency; there is no broadcast.
- DAD protects against duplicate addresses before use.
- NDP is unauthenticated β protect it with RA Guard and ND inspection at the access layer.
π§ͺ Want to practise this on your own computer? See how to set up your lab →