From 6cb8f742f1adf99881334b8ae21c398d98571aa1 Mon Sep 17 00:00:00 2001 From: Ondrej Zajicek Date: Wed, 27 Jan 2010 17:22:57 +0100 Subject: Better handling of well-known communities. Process well-known communities before the export filter (old behavior is to process these attributes after, which does not allow to send route with such community) and just for routes received from other BGP protocols. Also fixes a bug in next_hop check. --- proto/bgp/config.Y | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'proto/bgp/config.Y') diff --git a/proto/bgp/config.Y b/proto/bgp/config.Y index b2061a18..cf32cd16 100644 --- a/proto/bgp/config.Y +++ b/proto/bgp/config.Y @@ -23,7 +23,7 @@ CF_KEYWORDS(BGP, LOCAL, NEIGHBOR, AS, HOLD, TIME, CONNECT, RETRY, KEEPALIVE, BGP_ATOMIC_AGGR, BGP_AGGREGATOR, BGP_COMMUNITY, SOURCE, ADDRESS, PASSWORD, RR, RS, CLIENT, CLUSTER, ID, AS4, ADVERTISE, IPV4, CAPABILITIES, LIMIT, PASSIVE, PREFER, OLDER, MISSING, LLADDR, - DROP, IGNORE, ROUTE, REFRESH) + DROP, IGNORE, ROUTE, REFRESH, COMMUNITIES) CF_GRAMMAR @@ -86,6 +86,7 @@ bgp_proto: | bgp_proto PASSWORD TEXT ';' { BGP_CFG->password = $3; } | bgp_proto ROUTE LIMIT expr ';' { BGP_CFG->route_limit = $4; } | bgp_proto PASSIVE bool ';' { BGP_CFG->passive = $3; } + | bgp_proto IGNORE COMMUNITIES bool ';' { BGP_CFG->ignore_communities = $4; } ; CF_ADDTO(dynamic_attr, BGP_PATH -- cgit v1.2.3