]> git.puffer.fish Git - matthieu/frr.git/commitdiff
bgpd: Ignore RFC8212 for BGP Confederations
authorDonatas Abraitis <donatas@opensourcerouting.org>
Thu, 27 Jun 2024 19:46:58 +0000 (22:46 +0300)
committerMergify <37929162+mergify[bot]@users.noreply.github.com>
Mon, 1 Jul 2024 14:19:52 +0000 (14:19 +0000)
RFC 8212 should be restricted for eBGP peers.

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
(cherry picked from commit fa2cc09d45d3f843564f7bd1e02346373c5741a8)

bgpd/bgp_route.c

index a150795f0a09087a51badb211b54cae460a05ee0..5fb1b05ef96bb78da65289769d4ddf7c33ab40c3 100644 (file)
@@ -6024,7 +6024,8 @@ void bgp_set_stale_route(struct peer *peer, afi_t afi, safi_t safi)
 
 bool bgp_outbound_policy_exists(struct peer *peer, struct bgp_filter *filter)
 {
-       if (peer->sort == BGP_PEER_IBGP || peer->sub_sort == BGP_PEER_EBGP_OAD)
+       if (peer->sort == BGP_PEER_CONFED || peer->sort == BGP_PEER_IBGP ||
+           peer->sub_sort == BGP_PEER_EBGP_OAD)
                return true;
 
        if (peer->sort == BGP_PEER_EBGP &&
@@ -6037,7 +6038,8 @@ bool bgp_outbound_policy_exists(struct peer *peer, struct bgp_filter *filter)
 
 bool bgp_inbound_policy_exists(struct peer *peer, struct bgp_filter *filter)
 {
-       if (peer->sort == BGP_PEER_IBGP || peer->sub_sort == BGP_PEER_EBGP_OAD)
+       if (peer->sort == BGP_PEER_CONFED || peer->sort == BGP_PEER_IBGP ||
+           peer->sub_sort == BGP_PEER_EBGP_OAD)
                return true;
 
        if (peer->sort == BGP_PEER_EBGP