]> git.proxmox.com Git - mirror_frr.git/commitdiff
Revert "bgpd: Drop `internet` community check from community_list_match()"
authorDonatas Abraitis <donatas@opensourcerouting.org>
Wed, 24 Aug 2022 05:46:56 +0000 (08:46 +0300)
committerDonatas Abraitis <donatas@opensourcerouting.org>
Wed, 24 Aug 2022 05:46:56 +0000 (08:46 +0300)
Seems that, `internet` community is used to match ANY community.

This reverts commit e605d0cfae6a3fc9b65058ec85b55d7d0bd5cc22.

bgpd/bgp_clist.c

index bc6d4e144e7fdc15daa39a824366351d54e66084..34d4be8c93a27971ff076f6f8539538081c0379c 100644 (file)
@@ -674,6 +674,9 @@ bool community_list_match(struct community *com, struct community_list *list)
                        return entry->direct == COMMUNITY_PERMIT;
 
                if (entry->style == COMMUNITY_LIST_STANDARD) {
+                       if (community_include(entry->u.com, COMMUNITY_INTERNET))
+                               return entry->direct == COMMUNITY_PERMIT;
+
                        if (community_match(com, entry->u.com))
                                return entry->direct == COMMUNITY_PERMIT;
                } else if (entry->style == COMMUNITY_LIST_EXPANDED) {