uRPF Unicast Reverse Path Forwarding

uRPF Unicast Reverse Path Forwarding 单播的反向路径转发
uRPF功能是让路由器具备防IP欺骗或IP伪造的能力。
uRPF所认为的IP伪造,是指某个IP的数据包的并不应该从某个接口进来,却从某个接口进来了,那么这样的数据包便认为是具有IP欺骗性质的,默认是被丢弃的 。
当路由器从某个开启了uRPF的接口上收到数据包之后,都会检测该数据包的源IP地址,同时与路由表中的路由条目作对比,经过判断后,如果到达这个源IP的出口确实是这个开了uRPF的接口,则数据包被转发,否则被丢弃。
因为uRPF开启后,所有从此接口进入的数据包都要被检测,速度将会变慢,所以必须开启CEF后,才能开启uRPF。uRPF只能在in方向上开启,在做检查时,所有到源IP的最优路径都认为是可行的。
uRPF的两种模式

Strict Mode 严格模式
检查IP条目,接口
Strict checking mode verifies that the source IPv4 address of an IPv4 packet exists in the routing table and that the source IPv4 address is reachable by a path through the input interface (the interface on which the packet enters the router). To configure strict checking mode, use one of the following commands:

Router (config-if)# ip verify unicast source reachable-via rx

Router (config-if)# ip verify unicast reverse-path

Loose Mode 宽松模式
检测ip条目
To provide ISPs with a DDoS resistance tool on the ISP-to-ISP edge of a network, Unicast RPF was modified from its original strict mode implementation to check the source addresses of each ingress packet without regard for the specific interface on which it was received.
Example
Router (config-if)# ip verify unicast source reachable-via any
Enables Unicast RPF using loose mode.

在正常情况下,如果一个数据包无法通过uRPF检查,那么该数据包默认是丢弃的,但是有时因为特殊原因,可以让某些即使检查失败的数据包也能通过,要做到这一点,就可以在开启uRPF除加ACL,其中检查失败的数据包,是丢弃还是放行,全由ACL来决定,ACL允许,就放行,ACL拒绝,就丢弃
Router(config-if)#ip verify unicast reverse-path
接口上开启uRPF,默认检测进入接口的所有数据包。

Router(config)#access-list 100 permit ip host 3.3.3.3 any
Router(config-if)#ip verify unicast reverse-path 100

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值