Chapter 10: BGP Configuration Guide
108
DIGITAL GIGAswitch/Router User Reference Manual
Using AS-Path Regular Expressions
An AS-path regular expression is a regular expression where the alphabet is the set of AS
numbers. An AS-path regular expression is composed of one or more AS-path
expressions. An AS-path expression is composed of AS path terms and AS-path operators.
An AS path term is one of the following three objects:
autonomous_system
Is any valid autonomous system number, from one through 65534 inclusive.
.
(dot)
Matches any autonomous system number.
( aspath_regexp )
Parentheses group subexpressions. An operator, such as * or ? works on a single
element or on a regular expression enclosed in parentheses.
An AS-path operator is one of the following:
aspath_term {m,n}
A regular expression followed by {m,n} (where m and n are both non-negative
integers and m <= n) means at least m and at most n repetitions.
aspath_term {m}
A regular expression followed by {m} (where m is a positive integer) means exactly
m repetitions.
aspath_term {m,}
A regular expression followed by {m,} (where m is a positive integer) means m or
more repetitions.
aspath_term *
An AS path term followed by * means zero or more repetitions. This is shorthand
for {0,}.
aspat
A regular expression followed by + means one or more repetitions. This is
shorthand for {1,}.
aspath_term ?
A regular expression followed by ? means zero or one repetition. This is shorthand
for {0,1}.
aspath_term | aspath_term
Matches the AS term on the left, or the AS term on the right.