IPv6 Security — RA Guard & DHCPv6 Guard
IPv6 introduces powerful auto-configuration mechanisms — SLAAC (Stateless Address Autoconfiguration) and DHCPv6 — that allow hosts to configure themselves with an IPv6 address, prefix, and default gateway without manual intervention. Both mechanisms depend on trust: SLAAC relies on Router Advertisement (RA) messages sent by routers (see IPv6 Neighbour Discovery), and DHCPv6 relies on responses from a DHCPv6 server (see IPv6 DHCPv6 & SLAAC). An attacker on the same Layer 2 segment who sends crafted RA or DHCPv6 messages can hijack host configuration — redirecting all traffic through an attacker-controlled gateway, poisoning DNS, or creating a man-in-the-middle position with no ARP spoofing required.
RA Guard and DHCPv6 Guard are Cisco IOS IPv6 First Hop Security (FHS) features that enforce port-level policies on a switch. RA Guard drops Router Advertisement messages arriving on ports that are not trusted router ports — a host-facing access port should never originate an RA. DHCPv6 Guard drops DHCPv6 server reply messages (Advertise, Reply) on ports that are not designated DHCPv6 server ports. Both features work analogously to DHCP Snooping and Dynamic ARP Inspection for IPv4 — trusted ports allow infrastructure traffic; untrusted ports allow only client traffic.
Before starting, ensure you are familiar with IPv6 fundamentals at IPv6 Overview and address types at IPv6 Link-Local vs Global. For IPv6 address configuration on routers and interfaces, see IPv6 Basic Configuration. For DHCPv6 stateful and SLAAC operation, see IPv6 DHCPv6 & SLAAC. For the IPv4 equivalents of these First Hop Security features, see DHCP Snooping & Dynamic ARP Inspection.
1. IPv6 First Hop Security — Core Concepts
The Attack Surface: Rogue RA and Rogue DHCPv6
Understanding the attacks that RA Guard and DHCPv6 Guard prevent is essential before configuring the defences:
══ Attack 1: Rogue Router Advertisement (Rogue RA) ══════════════
Normal operation:
[Legitimate Router] ──RA (prefix 2001:db8:10::/64, GW fe80::1)──► [Hosts]
Hosts configure: 2001:db8:10::xxxx/64, default GW = fe80::1
Attack — any host can send RA (no protocol enforcement):
[Attacker PC] ──fake RA (prefix 2001:db8:99::/64, GW fe80::bad)──► [Hosts]
Hosts now configure: 2001:db8:99::xxxx/64, default GW = fe80::bad
► ALL host traffic is routed through the attacker's machine
► Man-in-the-middle, traffic interception, denial of service
══ Attack 2: Rogue DHCPv6 Server ════════════════════════════════
Normal operation:
[Host] ──DHCPv6 Solicit──► [Legitimate DHCPv6 Server]
◄──DHCPv6 Advertise (addr, prefix, DNS 2001:db8::53)──
Host configures valid DNS server
Attack — any host can respond to DHCPv6 Solicit:
[Host] ──DHCPv6 Solicit──► (multicast — all servers see it)
[Attacker] ◄─── sees Solicit, responds first with DHCPv6 Advertise
Attacker provides: malicious DNS server (2001:db8::bad:dns)
► Host uses attacker-controlled DNS → phishing, credential theft
IPv6 First Hop Security Feature Suite
RA Guard and DHCPv6 Guard are part of a broader suite of Cisco FHS features. This lab covers the two most important ones for the exam:
| Feature | Protects Against | Mechanism | IPv4 Equivalent |
|---|---|---|---|
| RA Guard | Rogue Router Advertisements — attacker poses as a router to redirect host traffic | Drops RA messages on host-facing (untrusted) ports; only router-facing (trusted) ports may forward RAs | No direct IPv4 equivalent (DHCP Snooping is closest for gateway assignment) |
| DHCPv6 Guard | Rogue DHCPv6 servers — attacker provides malicious DNS, prefix, or addressing information | Drops DHCPv6 server reply messages (Advertise, Reply) on client ports; only designated server ports may forward server replies | DHCP Snooping (IPv4) |
| IPv6 Snooping | Binding table attacks — builds and maintains a database of IPv6 address-to-port-to-MAC mappings | Inspects NDP and DHCPv6 traffic to build a trusted binding table used by other FHS features | DHCP Snooping binding table (IPv4) |
| IPv6 Source Guard | IPv6 source address spoofing — host sends packets with a source IPv6 address it was not assigned | Checks source IPv6 address against the IPv6 snooping binding table; drops packets with unrecognised source addresses | IP Source Guard / DHCP Snooping (IPv4) |
| IPv6 ND Inspection | Neighbour Discovery spoofing — fake Neighbour Advertisement messages to poison NDP caches | Validates NDP messages against the binding table; drops inconsistent NAs | Dynamic ARP Inspection (IPv4) |
RA Guard — How the Policy Model Works
RA Guard uses a named policy that defines the role of a port. The policy is created globally, then attached to one or more switch interfaces or VLANs:
| Policy Device Role | RA Messages | Applied To | Effect |
|---|---|---|---|
device-role router |
Permitted and forwarded | Uplink ports toward legitimate routers | Router can send RA through this port — normal operation |
device-role host |
Dropped | All access ports facing end hosts | Any RA arriving on this port is discarded — attacker on a host port cannot send rogue RAs |
DHCPv6 Guard — How the Policy Model Works
| Policy Device Role | DHCPv6 Server Messages (Advertise, Reply) | Applied To | Effect |
|---|---|---|---|
device-role server |
Permitted and forwarded | Uplink ports toward the legitimate DHCPv6 server | DHCPv6 server responses flow through this port normally |
device-role client |
Dropped | All access ports facing end hosts | Any DHCPv6 server reply arriving on this port is discarded — rogue DHCPv6 servers on host ports are silenced |
2. Lab Topology & Scenario
NetsTuts has a single IPv6 campus LAN segment. PC-A and PC-B are end
hosts connecting through NetsTuts_SW. The legitimate
router (NetsTuts_R1) sends Router Advertisements and
the DHCPv6 server runs on the router itself. An attacker on the same
segment (Attacker-PC, connected to Gi0/3) has been running
radvd and a rogue DHCPv6 server to redirect host traffic.
RA Guard and DHCPv6 Guard will be configured to harden all host ports.
NetsTuts_R1
Gi0/0: 2001:db8:10::1/64
fe80::1 (link-local)
DHCPv6 Server: enabled
Sends RA: enabled
|
Gi0/1 (TRUSTED — router port)
|
┌──────────────────────────┐
│ NetsTuts_SW │
│ IPv6 FHS enabled │
│ VLAN 10 │
└──────────────────────────┘
| | |
Gi0/2 Gi0/3 Gi0/4
(HOST port) (HOST port) (HOST port)
| | |
PC-A Attacker-PC PC-B
2001:db8: (rogue RA 2001:db8:
10::a/64 + DHCPv6) 10::b/64
Port Roles:
┌─────────┬──────────────────────────────┬──────────────────┬──────────────────┐
│ Port │ Connected To │ RA Guard Role │ DHCPv6 Guard Role│
├─────────┼──────────────────────────────┼──────────────────┼──────────────────┤
│ Gi0/1 │ NetsTuts_R1 (legit router) │ router (permit) │ server (permit) │
│ Gi0/2 │ PC-A (host) │ host (drop RA) │ client (drop svr)│
│ Gi0/3 │ Attacker-PC │ host (drop RA) │ client (drop svr)│
│ Gi0/4 │ PC-B (host) │ host (drop RA) │ client (drop svr)│
└─────────┴──────────────────────────────┴──────────────────┴──────────────────┘
3. Step 1 — Enable IPv6 First Hop Security on the Switch
IPv6 FHS features require the switch to be in
ipv6 unicast-routing mode (for Layer 3 switches) or, on
Layer 2 switches, the FHS features are enabled per-interface without
needing unicast routing. On both switch types, the VLAN must be
configured to allow FHS policy processing:
NetsTuts_SW>en NetsTuts_SW#conf t Enter configuration commands, one per line. End with CNTL/Z. ! ── Verify the switch supports IPv6 FHS ────────────────── ! ── (Cat 3560/3750/3850/9000 series support FHS) ───────── NetsTuts_SW(config)#sdm prefer dual-ipv4-and-ipv6 default ! ── Save and reload if SDM template was changed ────────── ! NetsTuts_SW(config)#end ! NetsTuts_SW#write memory ! NetsTuts_SW#reload ! ── Create and name the access VLAN ────────────────────── NetsTuts_SW(config)#vlan 10 NetsTuts_SW(config-vlan)#name IPv6-LAN NetsTuts_SW(config-vlan)#exit
sdm prefer dual-ipv4-and-ipv6 default command
allocates TCAM resources to support both IPv4 and IPv6 forwarding
and security features. On newer Catalyst platforms (3850, 9000) this
is the default — no SDM change is needed. On older 3560/3750 switches,
the default SDM template is IPv4-only and must be changed before IPv6
FHS features will work. A reload is required after changing the SDM
template. For interface basics, see
Basic Interface
Configuration.
4. Step 2 — Configure RA Guard Policies
Two RA Guard policies are needed: one for router-facing ports
(permits RA messages) and one for host-facing ports (drops RA
messages). The policy is created with
ipv6 nd raguard policy [name]:
! ══════════════════════════════════════════════════════════ ! RA Guard Policy 1: ROUTER-PORT ! Applied to uplinks toward legitimate routers ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#ipv6 nd raguard policy ROUTER-PORT NetsTuts_SW(config-ra-guard)#device-role router NetsTuts_SW(config-ra-guard)#exit ! ══════════════════════════════════════════════════════════ ! RA Guard Policy 2: HOST-PORT ! Applied to all access ports facing end hosts ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#ipv6 nd raguard policy HOST-PORT NetsTuts_SW(config-ra-guard)#device-role host NetsTuts_SW(config-ra-guard)#exit
device-role router policy permits Router Advertisements
to pass through the port — the legitimate router connected to Gi0/1 can
send RAs that reach the hosts normally. The device-role host
policy drops all RA messages arriving on that port — any device connected
to Gi0/2, Gi0/3, or Gi0/4 that sends an RA will have it silently
discarded by the switch before it reaches any other host on the segment.
Optional: Advanced RA Guard Policy — Validate RA Content
The RA Guard policy can go further and validate the content of Router Advertisements on trusted router ports — checking that the RA prefix matches the expected prefix and that the hop limit is reasonable. This catches misconfigured routers as well as attackers:
! ── Advanced ROUTER-PORT policy with content validation ── NetsTuts_SW(config)#ipv6 nd raguard policy ROUTER-PORT-STRICT NetsTuts_SW(config-ra-guard)#device-role router ! ── Only accept RAs advertising the expected prefix ─────── NetsTuts_SW(config-ra-guard)#match ra prefix-list RA-ALLOWED-PREFIXES ! ── Only accept RAs with hop-limit of 64 or higher ──────── NetsTuts_SW(config-ra-guard)#match ra hop-limit minimum 64 ! ── Managed/Other flags: validate against expected values ─ NetsTuts_SW(config-ra-guard)#match ra managed-config-flag on NetsTuts_SW(config-ra-guard)#exit ! ── Create the prefix list referenced by the policy ─────── NetsTuts_SW(config)#ipv6 prefix-list RA-ALLOWED-PREFIXES permit 2001:db8:10::/64 le 64
match ra prefix-list validates that the prefix advertised
in the RA matches the configured prefix list — a rogue RA with
a different prefix (e.g., 2001:db8:99::/64) would be dropped even
on a trusted router port. match ra hop-limit minimum 64
drops RAs with an abnormally low hop limit, which is a common indicator
of a crafted rogue RA. match ra managed-config-flag on
ensures the M-flag (telling hosts to use DHCPv6) matches the expected
state — preventing an attacker from clearing the M-flag to push hosts
back to SLAAC when the network uses stateful DHCPv6.
5. Step 3 — Configure DHCPv6 Guard Policies
DHCPv6 Guard policies follow the same model as RA Guard — a server policy for trusted server-facing ports and a client policy for all host-facing ports:
! ══════════════════════════════════════════════════════════ ! DHCPv6 Guard Policy 1: DHCPV6-SERVER-PORT ! Applied to uplinks toward the legitimate DHCPv6 server ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#ipv6 dhcp guard policy DHCPV6-SERVER-PORT NetsTuts_SW(config-dhcp-guard)#device-role server NetsTuts_SW(config-dhcp-guard)#exit ! ══════════════════════════════════════════════════════════ ! DHCPv6 Guard Policy 2: DHCPV6-CLIENT-PORT ! Applied to all access ports facing end hosts ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#ipv6 dhcp guard policy DHCPV6-CLIENT-PORT NetsTuts_SW(config-dhcp-guard)#device-role client NetsTuts_SW(config-dhcp-guard)#exit
device-role server policy allows DHCPv6 Advertise
and Reply messages to pass — the legitimate DHCPv6 server on
NetsTuts_R1 (connected via Gi0/1) can respond to client Solicits.
The device-role client policy silently drops all
DHCPv6 server messages arriving on host ports — the Attacker-PC
on Gi0/3 cannot respond to DHCPv6 Solicits from PC-A or PC-B
because the switch drops all DHCPv6 Advertise/Reply messages
from that port before they reach any other host.
Optional: Advanced DHCPv6 Guard — Validate Server Identity
! ── Validate that DHCPv6 server replies come from ──────── ! ── a known trusted server address prefix ───────────────── NetsTuts_SW(config)#ipv6 dhcp guard policy DHCPV6-SERVER-STRICT NetsTuts_SW(config-dhcp-guard)#device-role server ! ── Only permit replies from the expected server prefix ─── NetsTuts_SW(config-dhcp-guard)#match server access-list DHCPv6-SERVER-ACL ! ── Only permit replies advertising prefixes in this list ─ NetsTuts_SW(config-dhcp-guard)#match reply prefix-list DHCPV6-ALLOWED-PREFIXES NetsTuts_SW(config-dhcp-guard)#exit ! ── IPv6 ACL matching the legitimate DHCPv6 server ──────── NetsTuts_SW(config)#ipv6 access-list DHCPv6-SERVER-ACL NetsTuts_SW(config-ipv6-acl)#permit ipv6 2001:db8:10::1/128 any NetsTuts_SW(config-ipv6-acl)#exit ! ── Prefix list for allowed DHCPv6 address pool ─────────── NetsTuts_SW(config)#ipv6 prefix-list DHCPV6-ALLOWED-PREFIXES permit 2001:db8:10::/64 le 128
match server access-list validates the source IPv6
address of DHCPv6 server replies against an IPv6 ACL — only the
legitimate server at 2001:db8:10::1 can send replies through the
server port. match reply prefix-list validates the
prefixes being delegated in DHCPv6 replies — a rogue server
advertising an unexpected prefix would be dropped even if it
somehow reached a trusted port.
6. Step 4 — Apply Policies to Switch Interfaces
Policies are applied to interfaces using
ipv6 nd raguard attach-policy and
ipv6 dhcp guard attach-policy. Both policies can be
applied to the same interface simultaneously — a host port gets
both the RA Guard host policy and the DHCPv6 Guard client policy:
! ══════════════════════════════════════════════════════════ ! Gi0/1 — Uplink to NetsTuts_R1 (trusted router + DHCPv6) ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#interface GigabitEthernet0/1 NetsTuts_SW(config-if)#description Uplink to NetsTuts_R1 NetsTuts_SW(config-if)#switchport mode access NetsTuts_SW(config-if)#switchport access vlan 10 ! ── Apply RA Guard — router role (permit RAs) ──────────── NetsTuts_SW(config-if)#ipv6 nd raguard attach-policy ROUTER-PORT ! ── Apply DHCPv6 Guard — server role (permit replies) ──── NetsTuts_SW(config-if)#ipv6 dhcp guard attach-policy DHCPV6-SERVER-PORT NetsTuts_SW(config-if)#exit ! ══════════════════════════════════════════════════════════ ! Gi0/2 — PC-A (host port) ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#interface GigabitEthernet0/2 NetsTuts_SW(config-if)#description PC-A host port NetsTuts_SW(config-if)#switchport mode access NetsTuts_SW(config-if)#switchport access vlan 10 ! ── Apply RA Guard — host role (drop all RAs) ──────────── NetsTuts_SW(config-if)#ipv6 nd raguard attach-policy HOST-PORT ! ── Apply DHCPv6 Guard — client role (drop server replies) NetsTuts_SW(config-if)#ipv6 dhcp guard attach-policy DHCPV6-CLIENT-PORT NetsTuts_SW(config-if)#exit ! ══════════════════════════════════════════════════════════ ! Gi0/3 — Attacker-PC (host port — same policy as any host) ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#interface GigabitEthernet0/3 NetsTuts_SW(config-if)#description Host port (Attacker-PC blocked) NetsTuts_SW(config-if)#switchport mode access NetsTuts_SW(config-if)#switchport access vlan 10 NetsTuts_SW(config-if)#ipv6 nd raguard attach-policy HOST-PORT NetsTuts_SW(config-if)#ipv6 dhcp guard attach-policy DHCPV6-CLIENT-PORT NetsTuts_SW(config-if)#exit ! ══════════════════════════════════════════════════════════ ! Gi0/4 — PC-B (host port) ! ══════════════════════════════════════════════════════════ NetsTuts_SW(config)#interface GigabitEthernet0/4 NetsTuts_SW(config-if)#description PC-B host port NetsTuts_SW(config-if)#switchport mode access NetsTuts_SW(config-if)#switchport access vlan 10 NetsTuts_SW(config-if)#ipv6 nd raguard attach-policy HOST-PORT NetsTuts_SW(config-if)#ipv6 dhcp guard attach-policy DHCPV6-CLIENT-PORT NetsTuts_SW(config-if)#exit NetsTuts_SW(config)#end NetsTuts_SW#wr Building configuration... [OK] NetsTuts_SW#
7. Step 5 — Applying FHS Policies at the VLAN Level
In larger deployments with many access ports, applying policies per-interface is repetitive. Both RA Guard and DHCPv6 Guard support VLAN-level policy application — the policy is applied to the VLAN and automatically takes effect on all ports in that VLAN:
! ── Apply HOST-PORT RA Guard to all ports in VLAN 10 ────── NetsTuts_SW(config)#vlan configuration 10 NetsTuts_SW(config-vlan-config)#ipv6 nd raguard attach-policy HOST-PORT ! ── Apply DHCPv6 client guard to all ports in VLAN 10 ───── NetsTuts_SW(config-vlan-config)#ipv6 dhcp guard attach-policy DHCPV6-CLIENT-PORT NetsTuts_SW(config-vlan-config)#exit ! ── Override: apply router policy on the uplink only ────── ! ── Interface-level policy takes precedence over VLAN-level NetsTuts_SW(config)#interface GigabitEthernet0/1 NetsTuts_SW(config-if)#ipv6 nd raguard attach-policy ROUTER-PORT NetsTuts_SW(config-if)#ipv6 dhcp guard attach-policy DHCPV6-SERVER-PORT NetsTuts_SW(config-if)#exit
8. Verification
show ipv6 nd raguard policy
NetsTuts_SW#show ipv6 nd raguard policy
Target: GigabitEthernet0/1
Policy ROUTER-PORT configuration:
Device Role: Router
Max Hops: 255
Target: GigabitEthernet0/2
Policy HOST-PORT configuration:
Device Role: Host
Target: GigabitEthernet0/3
Policy HOST-PORT configuration:
Device Role: Host
Target: GigabitEthernet0/4
Policy HOST-PORT configuration:
Device Role: Host
show ipv6 nd raguard policy [name]
NetsTuts_SW#show ipv6 nd raguard policy HOST-PORT
Raguard policy HOST-PORT configuration:
Device Role: Host
Feature: Enabled
Targets:
GigabitEthernet0/2 vlan all
GigabitEthernet0/3 vlan all
GigabitEthernet0/4 vlan all
Raguard policy ROUTER-PORT configuration:
Device Role: Router
Feature: Enabled
Targets:
GigabitEthernet0/1 vlan all
show ipv6 dhcp guard policy
NetsTuts_SW#show ipv6 dhcp guard policy
DHCPv6 guard policy DHCPV6-CLIENT-PORT:
Device Role: DHCP Client
Targets:
GigabitEthernet0/2 vlan all
GigabitEthernet0/3 vlan all
GigabitEthernet0/4 vlan all
DHCPv6 guard policy DHCPV6-SERVER-PORT:
Device Role: DHCP Server
Targets:
GigabitEthernet0/1 vlan all
show ipv6 dhcp guard policy [name]
NetsTuts_SW#show ipv6 dhcp guard policy DHCPV6-CLIENT-PORT
DHCPv6 guard policy DHCPV6-CLIENT-PORT configuration:
Device Role: DHCP Client
Feature: Enabled
Targets:
GigabitEthernet0/2 vlan all
GigabitEthernet0/3 vlan all
GigabitEthernet0/4 vlan all
show ipv6 nd raguard statistics — Drop Counters
NetsTuts_SW#show ipv6 nd raguard statistics Interface Gi0/2 Gi0/3 Gi0/4 RA dropped: 0 47 0 RA forwarded: 0 0 0 Interface Gi0/1 RA dropped: 0 RA forwarded: 312
show ipv6 snooping features — FHS Feature Summary
NetsTuts_SW#show ipv6 snooping features Feature name priority state Ra-guard 150 READY DHCP-guard 100 READY
Functional Verification — Before and After
! ── On PC-A BEFORE RA Guard (attacker active) ──────────── PC-A$ ip -6 route show default default via fe80::bad dev eth0 proto ra ← Attacker's gateway! ! ── On PC-A AFTER RA Guard applied ─────────────────────── PC-A$ ip -6 route show default default via fe80::1 dev eth0 proto ra ← Legitimate router only ! ── Verify PC-A is using correct DNS (post DHCPv6 Guard) ─ PC-A$ cat /etc/resolv.conf nameserver 2001:db8:10::53 ← Legitimate DNS only
fe80::bad) as its default route — all traffic was
being routed through the attacker's machine. After RA Guard is applied,
only the legitimate router's RA (with gateway fe80::1) is
forwarded by the switch. PC-A now has the correct default gateway and
the man-in-the-middle position is eliminated.
Verification Command Summary
| Command | What It Shows | Primary Use |
|---|---|---|
show ipv6 nd raguard policy |
All RA Guard policies — device role, and all interfaces/VLANs each policy is applied to | Primary verification — confirm RA Guard is applied to every port with correct role |
show ipv6 nd raguard policy [name] |
Specific policy detail — device role, feature state, and list of attached targets | Confirm a named policy is enabled and attached to the expected interfaces |
show ipv6 dhcp guard policy |
All DHCPv6 Guard policies — device role (server/client) and attached targets | Confirm DHCPv6 Guard client policy is applied to host ports and server policy to uplinks |
show ipv6 dhcp guard policy [name] |
Specific DHCPv6 Guard policy detail — role, state, and attached interfaces | Verify a specific policy is active and applied to the correct ports |
show ipv6 nd raguard statistics |
Per-interface RA drop and forward counters | Confirm rogue RAs are being dropped (non-zero drop counter on attacker port) and legitimate RAs are forwarded (non-zero forward counter on router port) |
show ipv6 snooping features |
All active IPv6 FHS features and their state (READY / NOT READY) | Confirm all FHS features are initialised and operational on the switch |
show ipv6 snooping binding |
IPv6 First Hop Security binding table — MAC, IPv6 address, VLAN, interface, and how the entry was learned | Verify hosts have learned IPv6 addresses from the correct source; used by IPv6 Source Guard and ND Inspection |
show running-config interface [int] |
Interface config — confirms ipv6 nd raguard attach-policy and ipv6 dhcp guard attach-policy lines are present. See show running-config |
Quick audit of which policies are attached to a specific port |
9. Troubleshooting RA Guard & DHCPv6 Guard Issues
| Problem | Symptom | Cause | Fix |
|---|---|---|---|
| Hosts cannot get IPv6 addresses via SLAAC | After applying RA Guard, hosts no longer receive a global IPv6 address via SLAAC — they only have a link-local address | The router uplink port has the HOST-PORT policy (device-role host) instead of the ROUTER-PORT policy (device-role router) — the legitimate router's RA is being dropped along with the rogue ones | Run show ipv6 nd raguard policy — confirm the router port (Gi0/1) has device-role router. If it shows device-role host, re-attach the correct policy: interface Gi0/1 then ipv6 nd raguard attach-policy ROUTER-PORT. Test with show ipv6 nd raguard statistics — the router port should show RA forwarded, not RA dropped |
| Hosts cannot get addresses from DHCPv6 | After applying DHCPv6 Guard, hosts send DHCPv6 Solicit but receive no response — DHCPv6 address assignment fails | The DHCPv6 server uplink port has the DHCPV6-CLIENT-PORT policy (device-role client) instead of DHCPV6-SERVER-PORT (device-role server) — the server's Advertise/Reply messages are being dropped by the switch before reaching the client | Run show ipv6 dhcp guard policy — confirm the uplink port (Gi0/1) has device-role server. Re-attach if wrong: interface Gi0/1 then ipv6 dhcp guard attach-policy DHCPV6-SERVER-PORT. On a Layer 3 switch where the DHCPv6 server is on a different VLAN, the relay/server port facing that VLAN must also have the server policy |
show ipv6 nd raguard policy shows no output or no targets |
Policy is created but no interfaces are listed as targets — the policy exists but is not active anywhere | The policy was created with ipv6 nd raguard policy but ipv6 nd raguard attach-policy was never applied to any interface or VLAN |
Apply the policy: on each host port run ipv6 nd raguard attach-policy HOST-PORT. Verify with show ipv6 nd raguard policy HOST-PORT — targets should now list the attached interfaces |
| RA Guard not dropping rogue RAs despite correct policy | show ipv6 nd raguard statistics shows 0 dropped on the attacker port — rogue RAs are still reaching hosts |
The SDM template does not allocate TCAM for IPv6 FHS, or the switch platform does not support RA Guard in hardware on this port type, or the policy is attached to the wrong VLAN scope | Verify show sdm prefer — confirm the active template includes IPv6. If not, run sdm prefer dual-ipv4-and-ipv6 default and reload. Check show ipv6 snooping features — RA Guard state must be READY, not NOT READY |
| Advanced policy content validation drops legitimate RA | After adding match ra prefix-list, even the router port drops RAs — hosts can no longer auto-configure |
The prefix list does not include the exact prefix the router is advertising, or the prefix list has a le value that does not cover the advertised prefix length |
Run debug ipv6 nd raguard to see why RAs are being dropped — the debug output shows which match criterion failed. Check the prefix list: show ipv6 prefix-list RA-ALLOWED-PREFIXES — ensure the router's actual advertised prefix (from show ipv6 interface on the router) is covered |
| VLAN-level policy not working on newly added ports | A new host port added to VLAN 10 is not protected — rogue RAs from this port still propagate | VLAN-level policy was applied correctly but the new port has an interface-level override that takes precedence, or the VLAN-level policy was applied before the new port was assigned to VLAN 10 | Check show running-config interface [new-port] — remove any interface-level RA Guard policy that overrides the VLAN policy. Verify the port is in the correct VLAN with show vlan brief. VLAN-level FHS policies apply automatically to all ports that are currently and subsequently added to that VLAN |
Key Points & Exam Tips
- RA Guard prevents rogue Router Advertisement attacks by dropping RA messages on host-facing switch ports — only ports with
device-role routerare allowed to forward RAs. This stops any host from posing as a router to redirect IPv6 traffic through an attacker-controlled gateway. See also Login Security for complementary switch hardening. - DHCPv6 Guard prevents rogue DHCPv6 server attacks by dropping DHCPv6 Advertise and Reply messages on host-facing ports — only ports with
device-role serverforward DHCPv6 server responses. This stops rogue DHCPv6 servers from providing malicious DNS addresses or prefixes to clients. - Both features follow the same trusted / untrusted port model as IPv4 DHCP Snooping: infrastructure-facing ports are trusted (router/server role); host-facing access ports are untrusted (host/client role).
- Policies are created globally with
ipv6 nd raguard policy [name]andipv6 dhcp guard policy [name], then attached to interfaces withipv6 nd raguard attach-policy [name]andipv6 dhcp guard attach-policy [name]. Creating a policy without attaching it has no effect. - Interface-level policy takes precedence over VLAN-level policy when both are configured. This allows the efficient pattern of applying a host/client policy to the entire VLAN and then overriding only the uplink ports with router/server policies.
- The SDM template must allocate TCAM for IPv6 on older Catalyst platforms (3560/3750) — use
sdm prefer dual-ipv4-and-ipv6 defaultand reload. On modern platforms (3850/9000) this is the default. A wrong SDM template causes the FHS features to show NOT READY inshow ipv6 snooping features. - Advanced RA Guard policies can validate RA content on trusted router ports:
match ra prefix-list(prefix must match),match ra hop-limit minimum(abnormally low hop limit = crafted RA), andmatch ra managed-config-flag(M-flag consistency). This catches misconfigured routers as well as attackers. show ipv6 nd raguard statisticsshows per-interface RA drop and forward counters — the most direct evidence that RA Guard is active and blocking rogue RAs. Non-zero drop counters on host ports indicate attack traffic was blocked.- RA Guard and DHCPv6 Guard are part of the broader IPv6 First Hop Security suite, which also includes IPv6 Snooping (binding table), IPv6 Source Guard (anti-spoofing), and IPv6 ND Inspection (NDP cache protection). The full suite provides IPv6 equivalents of DHCP Snooping, IP Source Guard, and Dynamic ARP Inspection.
- On the exam: know the two device roles for each feature (router/host for RA Guard; server/client for DHCPv6 Guard), the three-step workflow (create policy → set role → attach to interface), the primary verification commands (
show ipv6 nd raguard policy,show ipv6 dhcp guard policy), and the IPv4 analogues for each FHS feature.