Concept Guide

L2 egress access list
If a rule is simply appended, existing counters are not aected.
Table 7. L2 and L3 Filtering on Switched Packets
L2 ACL Behavior L3 ACL Behavior Decision on Targeted Trac
Deny Deny L3 ACL denies.
Deny Permit L3 ACL permits.
Permit Deny L3 ACL denies.
Permit Permit L3 ACL permits.
NOTE: If you congure an interface as a vlan-stack access port, only the L2 ACL lters the packets. The L3 ACL applied to such
a port does not aect trac. That is, existing rules for other features (such as trace-list, policy-based routing [PBR], and QoS)
are applied to the permitted trac.
For information about MAC ACLs, refer to Layer 2.
Assign an IP ACL to an Interface
To pass trac through a congured IP ACL, assign that ACL to a physical interface, a port channel interface, or a VLAN.
The IP ACL is applied to all trac entering a physical or port channel interface and the trac is either forwarded or dropped depending on
the criteria and actions specied in the ACL.
The same ACL may be applied to dierent interfaces and that changes its functionality. For example, you can take ACL “ABCD” and apply it
using the in keyword and it becomes an ingress access list. If you apply the same ACL using the out keyword, it becomes an egress
access list. If you apply the same ACL to the Loopback interface, it becomes a Loopback access list.
Applying an IP ACL
To apply an IP ACL (standard or extended) to a physical or port channel interface, use the following commands.
1 Enter the interface number.
CONFIGURATION mode
interface interface slot/port
2 Congure an IP address for the interface, placing it in Layer-3 mode.
INTERFACE mode
ip address ip-address
3 Apply an IP ACL to trac entering or exiting an interface.
INTERFACE mode
ip access-group access-list-name {in} [implicit-permit] [vlan vlan-range | vrf vrf-range]
[layer3]
NOTE
:
The number of entries allowed per ACL is hardware-dependent. For detailed specication about entries allowed per ACL, refer
to your line card documentation.
One of the usage scenarios is to avoid ACL being applied on the L2 trac which comes in via ICL. The layer 3 keyword can be
used at the VLAN level.
4 Apply rules to the new ACL.
INTERFACE mode
124
Access Control Lists (ACLs)