通过二层访问控制列表,实现每天8:00~18:00时间段内对源MAC为00e0-fc01-0101的报文进行过滤
时间: 2024-02-21 21:58:38 浏览: 22
好的,针对你的问题,二层访问控制列表是一种基于MAC地址的过滤技术,可以实现对网络中的报文进行筛选。通过配置ACL规则,可以限制只有在特定时间段内、特定MAC地址的报文才能通过交换机。
具体实现方法如下:
1. 创建ACL规则:
```
access-list 100 permit host 00e0-fc01-0101
```
2. 配置时间段:
```
time-range filter-time
periodic daily 8:00 to 18:00
```
3. 将ACL规则应用到接口:
```
interface GigabitEthernet0/1
switchport mode access
switchport access vlan 10
switchport port-security maximum 2
switchport port-security
switchport port-security violation restrict
switchport port-security aging time 2
switchport port-security aging type inactivity
switchport port-security mac-address 00e0.fc01.0101
switchport port-security mac-address sticky
switchport port-security mac-address sticky 00e0.fc01.0101
switchport port-security mac-address sticky 0000.0000.0000 vlan access vlan 10
switchport port-security mac-address sticky 0000.0000.0000 vlan dynamic
switchport port-security mac-address sticky 0000.0000.0000 maximum 2 vlan dynamic
switchport port-security mac-address sticky 0000.0000.0000 vlan access vlan 10 maximum 2
switchport port-security mac-address sticky 0000.0000.0000 vlan access vlan 10 maximum 2 action shutdown
switchport port-security mac-address sticky 0000.0000.0000 vlan access vlan 10 maximum 2 action trap
switchport port-security mac-address 00e0.fc01.0101 vlan access vlan 10 access-group 100 in time-range filter-time
```
上述配置将ACL规则100应用到接口GigabitEthernet0/1上,并且限制只有在时间段filter-time内,源MAC地址为00e0-fc01-0101的报文才能通过交换机。
相关推荐
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![](https://img-home.csdnimg.cn/images/20210720083646.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)