Unicast Reverse Path Forwarding (uRPF) is a security feature used on routers to prevent IP address spoofing by ensuring that incoming packets arrive on the interface that the router would use to send return traffic to the source IP address.
π§ How uRPF Works
When a packet arrives on an interface, uRPF checks the source IP address against the router’s routing table to verify that:
-
The best return path (route to the source IP) goes out the same interface that the packet came in on.
If the check fails, the packet is dropped. This helps mitigate spoofed or misrouted traffic.
π Modes of uRPF
1. Strict Mode
-
The most secure.
-
Packet is accepted only if the source IP is reachable via the same interface the packet arrived on.
-
Ideal for single-homed or stub networks.
π΄ Can cause false drops in asymmetric routing environments.
2. Loose Mode
-
Packet is accepted if the source IP exists in the routing table, regardless of which interface it would be sent out.
-
Useful in multi-homed or asymmetric networks where strict mode would drop legitimate traffic.
3. VRF Mode / Feasible Mode (platform-dependent)
-
Checks against the CPE or VRF-specific table, adding flexibility.
π― Where uRPF Is Useful
✅ 1. ISP and Edge Routers
-
Prevents customers from sending traffic with spoofed source IPs.
-
uRPF in strict mode is ideal for customer-facing interfaces (assuming a default route toward the customer).
✅ 2. Data Centers
-
Protects against spoofed packets within server environments.
-
Useful when you have well-known subnets per interface.
✅ 3. Enterprise LANs
-
Enforces source IP consistency within trusted subnets.
✅ 4. DoS/DDoS Mitigation
-
Helps drop spoofed packets used in attacks (e.g., reflective DDoS).
⚠️ Cautions and Limitations
-
Strict mode breaks asymmetric routing.
-
Needs careful design and testing in multi-homed or ECMP environments.
-
Should not be applied blindly to core or transit interfaces.
π ️ Cisco Configuration Example (Strict Mode)
-
rx
= receive interface (strict mode)
Loose Mode:
✅ Summary
Mode | Behavior | Use Case |
---|---|---|
Strict | Source must be reachable via same interface | Single-homed, simple networks |
Loose | Source must be in routing table | Multi-homed, asymmetric routing |
Feasible | Source in feasible set (platform-specific) | Advanced, flexible use cases |