summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonatas Abraitis <donatas@opensourcerouting.org>2022-10-27 07:27:41 +0100
committerGitHub <noreply@github.com>2022-10-27 07:27:41 +0100
commiteeb83189b9a65bc95a7a8266231197ea106833ab (patch)
tree8cd78ca3045bcedce6492b3da28c7477671b4c94
parente3c117e19a0e905f748bb0fccf9d21399a2fb421 (diff)
parent8c4d4624d2619ac23f082c354064b48b1c7e2842 (diff)
Merge pull request #12204 from taspelund/soo_ip_fix
bgpd: Check for IP-format Site-of-Origin
-rw-r--r--bgpd/bgp_route.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c
index 693616e6d5..cbb597fdab 100644
--- a/bgpd/bgp_route.c
+++ b/bgpd/bgp_route.c
@@ -2418,7 +2418,7 @@ bool subgroup_announce_check(struct bgp_dest *dest, struct bgp_path_info *pi,
if (aspath_check_as_sets(attr->aspath))
return false;
- /* If neighbor sso is configured, then check if the route has
+ /* If neighbor soo is configured, then check if the route has
* SoO extended community and validate against the configured
* one. If they match, do not announce, to prevent routing
* loops.
@@ -2431,6 +2431,8 @@ bool subgroup_announce_check(struct bgp_dest *dest, struct bgp_path_info *pi,
if ((ecommunity_lookup(ecomm, ECOMMUNITY_ENCODE_AS,
ECOMMUNITY_SITE_ORIGIN) ||
ecommunity_lookup(ecomm, ECOMMUNITY_ENCODE_AS4,
+ ECOMMUNITY_SITE_ORIGIN) ||
+ ecommunity_lookup(ecomm, ECOMMUNITY_ENCODE_IP,
ECOMMUNITY_SITE_ORIGIN)) &&
ecommunity_include(ecomm, ecomm_soo)) {
if (bgp_debug_update(NULL, p, subgrp->update_group, 0))