IRDP Spoofing Explained: How It Works, How It Differs From ICMP Redirect, and How to Defend

Learn what IRDP spoofing is, how attackers use ICMP redirect messages for man-in-the-middle attacks, and how to prevent them. Includes tools, commands, and real-world use cases.

Jul 03, 2025 - 11:01
Updated: 1 month ago
102.3k
IRDP Spoofing Explained: How It Works, How It Differs From ICMP Redirect, and How to Defend

Quick answer: IRDP spoofing is an attack where someone on the local network sends forged ICMP Router Advertisement messages so hosts adopt the attacker as their default gateway, enabling interception or denial of service. It only works against hosts that act on IRDP. Defend by disabling IRDP, using fixed gateways and securing the access layer.

Key takeaways

  • IRDP (RFC 1256) uses unauthenticated ICMP router advertisements, type 9.
  • It needs local access and a victim that actually listens to IRDP, so it is rare today.
  • It is different from ICMP redirect (type 5) and from ARP spoofing.
  • Disable IRDP, ignore redirects where not needed, and protect access ports.

What is IRDP?

The ICMP Router Discovery Protocol (IRDP) lets a host find routers on its subnet without being configured by hand. Routers send ICMP Router Advertisement messages (type 9), and hosts can ask for them with Router Solicitation (type 10). It is defined in RFC 1256 from 1991: RFC 1256.

The weakness is the same one found in many old protocols: the advertisement is not authenticated. A host that listens to IRDP will believe any router advertisement that arrives on its link.

What IRDP spoofing means

IRDP spoofing is when someone on the same network segment sends forged router advertisements so that listening hosts adopt a different device as their default gateway. Traffic then passes through that device. From there it can be read, changed or dropped, which makes it a man-in-the-middle (MITM) or denial-of-service attack.

Two conditions must hold: the attacker must be on the local segment, and the victim must actually act on router advertisements. That second condition is why this attack is rare today.

Is it still a real risk?

For most networks, it is low. Many modern operating systems do not use IRDP by default, and routers normally have it switched off. It is more of a risk on old systems, unusual embedded devices and networks where IRDP was turned on deliberately. Do not assume either way for your estate: check.

  • Linux: the kernel does not process IRDP by itself. A router discovery client daemon would have to be running.
  • Cisco IOS: IRDP is configured per interface and is not on unless an administrator enables it with ip irdp.
  • Windows: router discovery is a per-interface setting that can be inspected with netsh interface ipv4 show interface. Behaviour differs between versions, so test your own builds.

Do not confuse it with ICMP redirect

An earlier version of this article mixed up two different things. ICMP redirect (type 5) is a message from a router telling a host that a better next hop exists for a destination. It is a separate mechanism with a separate fix.

IRDP spoofingICMP redirect abuseARP spoofing
MessageRouter advertisement (type 9)Redirect (type 5)ARP reply
EffectChanges default gatewayChanges route for specific destinationsMaps gateway IP to attacker's MAC
Layer3 (ICMP)3 (ICMP)2 (ARP)
Needs local accessYesYes, usuallyYes
Main defenceDo not run IRDP; static gatewayIgnore redirectsDynamic ARP inspection, port security

The IPv6 version of the same idea is a rogue Router Advertisement, which is defended with RA Guard on switches.

How do you check your own lab?

Do this on a VM or machine you own. The aim is to find out what your systems will accept, not to attack anything.

  1. Check redirect handling on Linux: sysctl net.ipv4.conf.all.accept_redirects and net.ipv4.conf.all.secure_redirects. A value of 0 means redirects are ignored.
  2. Check whether a router discovery daemon is running: systemctl list-units | grep -i rdisc or ps aux | grep -i rdisc.
  3. On a Windows lab VM, view the interface settings with netsh interface ipv4 show interface and look at the router discovery line.
  4. Capture traffic in Wireshark on the lab segment with the filter icmp.type == 9 || icmp.type == 10 || icmp.type == 5 and see whether any advertisements or redirects appear. On a normal network you will usually see none.

Testing for this against a network you do not own, or without written approval, is illegal under the IT Act. Keep experiments inside a lab segment.

Prevention

  1. Do not run IRDP. Disable it on routers (no ip irdp on Cisco interfaces) and do not install router discovery clients on servers.
  2. Use a configured default gateway through DHCP or static settings, especially on servers and critical hosts.
  3. Ignore redirects. On Linux set net.ipv4.conf.all.accept_redirects=0 and net.ipv4.conf.all.send_redirects=0 on hosts that do not need them. Persist the change in /etc/sysctl.d/.
  4. Control the access layer. Port security, DHCP snooping, dynamic ARP inspection and RA Guard limit what an untrusted port can send.
  5. Segment the network. Keep guest and untrusted devices off the segments where servers live.
  6. Encrypt traffic. HTTPS, SSH and VPNs mean an intercepted stream is far less useful.
  7. Monitor. Alert on unexpected ICMP type 9 or type 5 messages in IDS or flow data.

Detection signs

  • A host's default gateway changes without a DHCP or admin change.
  • Route tables show host routes pointing to an unexpected next hop.
  • Latency or traceroute shows an extra hop before the usual gateway.
  • Router advertisements arrive from an address that is not a known router.

Why learn about it?

IRDP is a clean example of an unauthenticated discovery protocol. The same lesson applies to ARP, DHCP, IPv6 router advertisements and many others: if a device will believe any message on the wire, the access layer has to be protected. Knowing this helps in CEH, CCNA security topics and network design work.

Next steps

For hands-on attack and defence practice in a lab, see the VAPT course. Related reading: understanding man-in-the-middle attacks and MAC spoofing and how to prevent it.

Frequently Asked Questions

IRDP spoofing is sending forged ICMP Router Advertisement messages on a local network so hosts that listen to them adopt the attacker as their default gateway. Traffic can then be intercepted, altered or dropped.

The ICMP Router Discovery Protocol, defined in RFC 1256, lets hosts discover routers on their subnet through ICMP Router Advertisement and Solicitation messages. It does not authenticate those messages, which is the root of the weakness.

It is a low risk on most networks because many modern systems do not act on IRDP by default. It remains relevant for legacy or unusual devices and where IRDP was enabled deliberately, so check your own systems.

IRDP spoofing changes a host's default gateway using router advertisements (type 9). ICMP redirect abuse sends type 5 messages to change the route for particular destinations. They are separate mechanisms with different defences.

Do not run IRDP on routers or hosts, configure default gateways statically or through DHCP, ignore ICMP redirects where not needed, and use switch protections such as port security and dynamic ARP inspection.

IRDP spoofing works at layer 3 by forging router advertisements to change the default gateway. ARP spoofing works at layer 2 by forging ARP replies that map the gateway's IP to the attacker's MAC address.

What's Your Reaction?

Like Like 0
Dislike Dislike 0
Love Love 0
Funny Funny 0
Wow Wow 0
Sad Sad 0
Angry Angry 0
Vaishnavi

Vaishnavi is a skilled tech professional at the Ethical Hacking Training Institute in Pune, responsible for managing and optimizing the technical infrastructure that supports advanced cybersecurity education. With deep expertise in network security, backend operations, and system performance, she ensures that practical labs, online modules, and assessments run smoothly and securely. Her behind-the-scenes contributions play a vital role in delivering a seamless and secure learning experience for aspiring ethical hackers.