OS10 Enterprise Edition User Guide Release 10.4.0E(R3)


ip as-path access-list

Create an AS-path ACL filter for BGP routes using a regular expression.

ip as-path access-list name {deny | permit} regexp-string
  • name — Enter an access list name.
  • deny | permit — Reject or accept a matching route.
  • regexp-string — Enter a regular expression string to match an AS-path route attribute.
Not configured
Command Mode
Usage Information

You can specify an access-list filter on inbound and outbound BGP routes. The ACL filter consists of regular expressions. If a regular expression matches an AS path attribute in a BGP route, the route is rejected or accepted. The AS path does not contain the local AS number. The no version of this command removes a single access list entry if you specify deny and a regexp. Otherwise, the entire access list is removed.

These operator characters are not supported in the regular expressions you specify in the ip as-path access-list command. All other special characters are supported. Note the workaround available to use the space character as a match criteria for BGP AS paths.

Table 1. Special characters that are not supported. Special characters that are not supported
Operator Meaning Workaround
? (question mark) Make previous character optional. None; not supported in OS10.
\ (backslash) Treat the following character literally or give it a special meaning. None; not supported in OS10.
(space) Match space character. Use [[:punct:]] or "," (comma). The space between AS numbers in an AS path is expressed present using a "," (comma) internally. A punctuation posix expression or "," matches it.
_ (underscore) Match space, comma, brackets, start and end of a string. None; not supported in OS10.
OS10(config)# ip as-path access-list abc deny 123
Supported Release
10.3.0E or later

Rate this content

Easy to understand
Was this article helpful?
0/3000 characters
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please select whether the article was helpful or not.
  Comments cannot contain these special characters: <>()\