diff options
| author | Donatas Abraitis <donatas@opensourcerouting.org> | 2023-05-10 23:37:47 +0300 |
|---|---|---|
| committer | Donatas Abraitis <donatas@opensourcerouting.org> | 2023-05-11 11:39:23 +0300 |
| commit | 1c035c8c2c1bc57699697e7d35a631c9e6a1df55 (patch) | |
| tree | 9b30bc92148b571a44cc1dfc177827d2ea9ec8ab /lib/routemap.h | |
| parent | 052fa79dd23d5d495ea81a962633fe896054bb37 (diff) | |
bgpd: Implement `match source-protocol` for route-maps
The main idea is to filter routes by matching source (originating) protocol
for outgoing direction. For instance, filter outgoing routes to an arbitrary
router that are static only. Or filter out only routes learned from RIP.
Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
Diffstat (limited to 'lib/routemap.h')
| -rw-r--r-- | lib/routemap.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/routemap.h b/lib/routemap.h index 9b2e18b4a7..7277744dc5 100644 --- a/lib/routemap.h +++ b/lib/routemap.h @@ -259,6 +259,8 @@ DECLARE_QOBJ_TYPE(route_map); (strmatch(C, "frr-zebra-route-map:ipv4-next-hop-prefix-length")) #define IS_MATCH_SRC_PROTO(C) \ (strmatch(C, "frr-zebra-route-map:source-protocol")) +#define IS_MATCH_BGP_SRC_PROTO(C) \ + (strmatch(C, "frr-bgp-route-map:source-protocol")) #define IS_MATCH_SRC_INSTANCE(C) \ (strmatch(C, "frr-zebra-route-map:source-instance")) /* BGP route-map match conditions */ |
