access-list
To define the access list, use the access-list command in policy configuration mode. To remove the access list, use the no form of this command.
access-list access-list-name [ sequence sequence-value [ match [ destination-ip dest-ip/length | source-ip src-ip/length | destination-port dest-port-range | source-port src-port-range | destination-data-prefix-list prefix | source-data-prefix-list prefix | destination-tag-instance dest-tag-name | source-tag-instance src-tag-name ] action { accept | [ class | count ] | drop | count } | action ] | default-access | drop accept ]
no access-list
Syntax Description
destination-data-prefix-list |
(Optional) Specifies the destination prefix list. |
destination-ip |
(Optional) Specifies the list of destination addresses. |
destination-port |
(Optional) Specifies the list of destination ports. |
count |
(Optional) Specifies the number of packets/bytes matching this rule drop. |
destination-tag-instance |
(Optional) Specifies the name of the destination tag instance. Valid range is from 1 to 127 characters. |
source-data-prefix-list |
(Optional) Specifies the source data prefix list. |
source-ip |
(Optional) Specifies the list of source IP addresses. |
source-port |
(Optional) Specifies the list of source ports. |
source-tag-instance |
(Optional) Specifies the name of the source tag instance. Valid range is from 1 to 127 characters. |
Command Default
The access list defaults to an implicit deny statement for everything. An implicit deny statement terminates an access list.
Command Modes
Policy configuration (config-policy)
Command History
Release |
Modification |
---|---|
Cisco IOS XE Release 17.2.1v |
Command qualified for use in Cisco vManage CLI templates. |
Cisco IOS XE Catalyst SD-WAN Release 17.9.1a |
This command was modified. Policy match configuration is enhanced to include source-tag-instance and destination-tag-instance keyword parameters in ACL-matching attributes. |
Usage Guidelines
After ACL is defined, it can be applied to an interface.
The following is a sample output of this command:
access-list acl1
sequence 10
match
destination-ip 172.16.5.10
!
action drop
default-action accept
action drop
count 192-167-199-DROP-CNT
access-list 4451-Marking-Spoke
sequence 1
match
destination-ip 172.16.10.5
!
action accept
count SSL
class LLQ
count EXCHANGE
class CONTROL-SIGNALING
The following example shows how to configure source-tag-instance in a localized policy:
policy
lists
data-prefix-list pfx1
ip-prefix 10.20.24.0/24
!
!
access-list acl
sequence 10
match
source-tag-instance red
!
action accept
count acl_input_wc
!
!
default-action drop
!
!