Administrator Guide

Layer 3 Routing Commands 1275
no ip as-path access-list as-path-list-number
as-path-list-number—A number from 1 to 500 uniquely identifying the
list. All AS path access list commands with the same as-path-list-number
are considered part of the same list.
permit—Permit routes whose AS Path attribute matches the regular
expression.
deny—Deny routes whose AS Path attribute matches the regular
expression.
regexp—A regular expression used to match the AS path attribute of a
BGP path where the AS path is treated as an ASCII string.
Default Configuration
No AS path lists are configured by default. There are no default values for any
of the parameters of this command.
Command Mode
Global Configuration mode
User Guidelines
An AS path access list filters BGP routes on the AS path attribute of a BGP
route. The AS path attribute is a list of the autonomous system numbers
along the path to the destination. An AS path access list is an ordered
sequence of statements. Each statement specifies a regular expression and a
permit or deny action. If the regular expression matches the AS path of the
route expressed as an ASCII string, the route is considered a match and the
statement’s action is taken. An AS path list has an implicit deny statement at
the end. If a path does not match any of the statements in an AS path list, the
action is considered to be deny.
Once an path list is created, individual statements cannot be deleted from it.
To remove an individual statement, delete the AS path list and recreate it
without the statement to be deleted.
Statements are applied in the order in which they are created. New
statements are added to the end of the list. The statement with the first
matching regular expression is applied.