Prefix Lists and Prefix Trees
The user can create prefix lists or prefix trees and configure routemaps to allow or reject the lists.
List |
Description |
---|---|
Prefix List |
Simulate a sequential lookup and return the first matched entry as the true match. Prefix list name:
|
Prefix Tree |
Return the longest match as the true match. |
Prefix List Syntax

|

|

|

Configure a prefix list called non-local to restrict prefixes 192.168.0.0/16, 10.0.0.0/8, and 172.16.0.0/12, but allow all other IPv4 prefixes:
|

Configure a prefix-list called "no-5-net" to restrict prefix 5.0.0.0/8 but allow all other /8 prefixes.
Any other prefixes will not be matched by this list (and therefore will be restricted unless another prefix list matches them):
|
Prefix Tree Syntax

|

|

|

Configure a prefix tree called non-local to restrict all prefixes with mask lengths, which are shorter than or equal to /8, 192.168.0.0/16, and 172.16.0.0/12, but allow all other IPv4 prefixes:
|

Configure a prefix tree named "10-net" to allow 10.1.1.0/24, restrict all sub-prefixes of 10.1.0.0/16, and allow all sub-prefixes of 10.0.0.0/8, except 10.0.0.0/8 itself.
Any other prefixes will not be matched by this list (and thus will be restricted unless another prefix tree matches them):
|