From 960035b2d9e8300c91276922158b806b043e2e9b Mon Sep 17 00:00:00 2001 From: "G. Paul Ziemba" Date: Fri, 23 Mar 2018 16:57:03 -0700 Subject: bgpd: nexthop tracking with labels for vrf-vpn leaking Routes that have labels must be sent via a nexthop that also has labels. This change notes whether any path in a nexthop update from zebra contains labels. If so, then the nexthop is valid for routes that have labels. If a nexthop update has no labeled paths, then any labeled routes referencing the nexthop are marked not valid. Add a route flag BGP_INFO_ANNC_NH_SELF that means "advertise myself as nexthop when announcing" so that we can track our notion of the nexthop without revealing it to peers. Signed-off-by: G. Paul Ziemba --- tests/bgpd/test_mpath.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/bgpd/test_mpath.c b/tests/bgpd/test_mpath.c index 247fcf7da..2168bd5b7 100644 --- a/tests/bgpd/test_mpath.c +++ b/tests/bgpd/test_mpath.c @@ -105,9 +105,10 @@ static struct bgp *bgp_create_fake(as_t *as, const char *name) for (afi = AFI_IP; afi < AFI_MAX; afi++) for (safi = SAFI_UNICAST; safi < SAFI_MAX; safi++) { - bgp->route[afi][safi] = bgp_table_init(afi, safi); - bgp->aggregate[afi][safi] = bgp_table_init(afi, safi); - bgp->rib[afi][safi] = bgp_table_init(afi, safi); + bgp->route[afi][safi] = bgp_table_init(bgp, afi, safi); + bgp->aggregate[afi][safi] = bgp_table_init( + bgp, afi, safi); + bgp->rib[afi][safi] = bgp_table_init(bgp, afi, safi); bgp->maxpaths[afi][safi].maxpaths_ebgp = MULTIPATH_NUM; bgp->maxpaths[afi][safi].maxpaths_ibgp = MULTIPATH_NUM; } -- cgit v1.2.3