-
Configuration
-
Named IPv4 ACLs
-
Create a named IPv4 ACL
- Router(config)# ip access-list {standard | extended} <name>
-
After the ACL name is created, reference this name in interface configuration mode to create access control entries (ACEs)
- Router(config-if)# ip access-group <name> {in|out}
- Router(config-ext-nacl)# {deny|permit} <source> <source_wildcard> [log]
- Router(config-ext-nacl)# {deny|permit} {tcp|udp}<source> <source_wildcard> [operator <port>] <destination> <destination_wildcard> [operator <port>] [log]
- Router(config-ext-nacl)# {deny|permit} <source> <source_wildcard> <destination> <destination_wildcard> [log]
-
Apply the ACL to a virtual terminal (VTY) interface
- Router(config)# ip access-class <name> {in|out}
-
Numbered IPv4 ACLs
-
Extended Numbered IPv4 ACLs
-
Create an Extended numbered IPv4 ACL
- Create an Extended numbered IPv4 ACL that permits or denies IP traffic
- access-list <number>
- [dynamic <name> [timeout <minutes>]{deny|permit} <protocol> <source_address> <source_wildcard> <destination_address> <destination_wildcard> [precedence <value>] [tos <value>] [log|log-input] [time-range <time-range>]
- Create an Extended numbered IPv4 ACL that permits or denies ICMP traffic
- access-list <number>
- [dynamic <name> [timeout <minutes>]]{deny|permit} icmp <source_address> <source_wildcard> <destination_address> <destination_wildcard> [<icmp_type> [<icmp_code>] |<icmp_message>] [precedence <value>] [tos <value>] [log|log-input] [time-range <time-range>]
- Create an Extended numbered IPv4 ACL that permits or denies TCP traffic
- access-list <number>
- [dynamic <name> [timeout <minutes>]]{deny|permit} tcp <source_address> <source_wildcard> [operator [<port>]] <destination_address> <destination_wildcard> [operator [<port>]] [established] [precedence <value>] [tos <value>] [log|log-input] [time-range <time-range>]
- Create an Extended numbered IPv4 ACL that permits or denies UDP traffic
- access-list <number>
- [dynamic <name> [timeout <minutes>]]{deny|permit} udp <source_address> <source_wildcard> [operator [<port>]] <destination_address> <destination_wildcard> [operator [<port>]] [precedence <value>] [tos <value>] [log|log-input] [time-range <time-range>]
-
Apply an Extended numbered IPv4 ACL inbound or Outbound on a physical interface:
- ip access-group {number|name} {in|out}
-
Apply an ACL to a virtual terminal (VTY) interface
- Router(config-if)# ip access-class <number> {in|out}
-
Standard Numbered IPv4 ACLs
-
Create a standard numbered IPv4 ACL
- Router(config)# access-list <number> {permit | deny} {host | <source_ip> <source_wildcard> | any}
-
After the ACL is defined, apply it to an interface, inbound or outbound
- Router(config-if)# ip access-group <number> {in|out}
-
Apply an ACL to a virtual terminal (VTY) interface
- Router(config-if)# ip access-class <number> {in|out}
-
Troubleshooting
-
List all ACLs on a device
- show access-lists
- show access-lists [number|name]
-
List all IP ACLs on a device
- show ip access-lists
- show ip access-lists [number|name]
-
List configuration information about an interface, including ACLs configured to affect it
- show ip interface <type> <number>