ACL:access-list,访问控制列表

acl两种:
基本acl:(2000-2999):只能匹配源ip地址
高级acl:(3000-9000):可以匹配源ip、目标ip、源端口、目标端口等三层和四层的字段
注1:一个接口的同一个方向只能调用一个acl
注2:一个acl里面可以有多个rule规则,从上往下依次执行。
注3:数据包一旦被某rule匹配,就不继续向下匹配。
注4:默认隐含放过所有(华为的acl用来拒绝数据包时)
HCNA-ACL
acl举例:拒绝PC1访问172.16.10.x网段
R2:
acl number 2000 建立基本acl(表号2000)
rule 5 deny source 192.168.10.1 0 拒绝源地址为192.168.10.1的任何数据包。5为自动生成的执行序号(也可以自己加)。

int gi0/0/1
traffic-filter inbound acl 2000在接口的入方向调用acl

acl举例在R2上配置高级acl拒绝PC1和PC2 ping Server1,但是允许其http访问Server1
R2:
acl 3000
rule 5 deny icmp source 192.168.10.0 0.0.0.255 destination 172.16.10.2 0

int gi0/0/1
traffic-filter inbound acl 3000

acl举例:拒绝源地址192.168.10.2的telent的访问
acl 3000:
rule 5 deny tcp source 192.168.10.2 0 destination 12.1.1.2 0 destination-port eq telent

int gi0/0/1
traffic-filter inbound acl 3000

相关文章:

  • 2021-12-02
  • 2021-05-16
  • 2021-05-10
  • 2021-08-02
  • 2021-10-13
  • 2021-10-14
  • 2021-06-03
猜你喜欢
  • 2021-08-06
  • 2021-07-14
  • 2021-04-28
  • 2021-10-21
  • 2021-11-01
  • 2021-11-13
  • 2021-09-02
相关资源
相似解决方案