Wednesday 20 February 2008

AS-Path Filters

Service providers use AS-Path filters to influence BGP route selection. AS-path filters use regular expressions. These are character definitions that use to construct regular expressions :

^ Start of string
$ End of string
[] Range of characters
- Used to specify range ( i.e. [0-9] )
( ) Logical grouping
. Any single character
* Zero or more instances
+ One or more instance
? Zero or one instance
_ Matches any delimiter

Sample regular expressions :

_123_ Going through AS 123
^123$ Directly connected to AS 123
_123$ Originated in AS 123
^123_. Network behind AS 123
^$ Networks originated in local AS
.* Matches everything

No comments: