Configuring the Filter
Context
A filter contains packet characteristics specified by users, and the device processes the packets matching these characteristics first. You can configure a filter by using an ACL.
- Basic ACL: source, time-range
- Advanced ACL: protocol, source, time-range, ttl-expired, source-port, destination-port, igmp-type
- Basic ACL6: source, time-range
- Advanced ACL6: protocol, source, time-range, source-port, icmp6-type, destination-port
- Basic ACL: vpn-instance
- Advanced ACL: vpn-instance, icmp-type, igmp-type
- Basic ACL6: vpn-instance
- Advanced ACL6: destination, vpn-instance, icmpv6-type
- Basic ACL: vpn-instance
- Advanced ACL: vpn-instance
- Basic ACL6: vpn-instance
- Advanced ACL6: destination, dscp, vpn-instance
When a blacklist and a filter are configured and the same ACL is applied to them, the filter takes effect.
For the CE12800 running V200R002C50 and later versions, the filter no longer supports advanced ACLs with the source port number and TCP flag as matching rules. If a filter using the source port number or TCP flag as a matching rule is configured on a switch running a version earlier than V200R002C50, the filter becomes invalid after the switch is upgraded to V200R002C50 or a later version.
If protocol and destination-port are configured in the ACL, the delivered protocol and destination port number are the same as the protocol and destination port number corresponding to the packet type specified during filter configuration.
Procedure
- Run system-view
The system view is displayed.
- Run cpu-defend policy policy-name
The attack defense policy view is displayed.
- Run any of the following commands to configure a filter:
- filter packet-type arp acl acl-number
An ARP-based ACL can be applied to a filter.
Only the CE12800E equipped with FD-X series cards supports this command.
- filter packet-type { icmp | igmp | ospf | dhcp } acl acl-number
A basic ACL or an advanced ACL can be applied to a filter.
- filter packet-type { icmpv6 | ospfv3 | dhcpv6 } acl ipv6 acl6-number
A basic ACL6 or an advanced ACL6 can be applied to a filter.
- filter packet-type { snmp | dns | ftp | telnet | ssh | bgp } acl { acl-number | ipv6 acl6-number }
A basic ACL, an advanced ACL, a basic ACL6, or an advanced ACL6 can be applied to a filter.
By default, no filter is available on a device.
For details about ACL configuration, see ACL Configuration.
- filter packet-type arp acl acl-number
- Run commit
The configuration is committed.