ip aspath-list


ip aspath-list <ASPATH-LIST-NAME> [seq <SEQ>] {permit | deny} <REGEXP>

no ip aspath-list <ASPATH-LIST-NAME> [seq <SEQ>] {permit | deny} <REGEXP>


Configures an AS Path list to match a specific AS path. AS Path lists are named lists of regular expression rules. They are used to match AS Path attributes in the routes for inclusion in or exclusion from route policies. The sequence number is optional and is autogenerated whenever it is not explicitly mentioned. All AS Path list rules with the same name are grouped together.

The no form of this command removes the AS Path list configuration.

Command context




Specifies the name of the AS Path list.

seq <SEQ>

Specifies the order of reference of the regular expression rules.

{permit | deny}

Specifies whether the route is available for further processing when there is a match.


Specifies the regular expression to match the AS Path. Standard regular expression wildcards are supported. The _ character can be used to match the AS Path boundary.




Configuring an AS Path list with sequence numbering:

switch(config)# ip aspath-list ASLst seq 5 permit _4*

Configuring a prefix list without sequence numbering:

switch(config)# ip aspath-list ASLst permit _4*