【Huawei ACL】Prohibit a certain network segment from accessing the Internet

The 192.168.4.0 network segment is prohibited from accessing the ISP network.

Forbid the 4.0 network segment to pass through the switch 0/0/22 interface.

[Huawei]acl 2001 //定义一个序号为2001的acl表
[Huawei-acl-basic-2001]rule deny source 192.168.4.0 0.0.0.255 //拒绝来自源地址是192.168.4.0/24的数据包
[Huawei-acl-basic-2001]quit //退出acl编辑模式

[Huawei]interface Ethernet 0/0/22 //进入接口
[Huawei-Ethernet0/0/22]traffic-filter outbound acl 2001 //应用acl表,(outbound代表禁止转出)

 

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325253544&siteId=291194637