summaryrefslogtreecommitdiff
path: root/zebra/kernel_socket.c
diff options
context:
space:
mode:
authorTrey Aspelund <taspelund@nvidia.com>2022-07-26 22:04:14 +0000
committerTrey Aspelund <taspelund@nvidia.com>2022-08-04 20:36:49 +0000
commit7226bc40d606e30251024032995ff21c391ad19f (patch)
tree375eda5248ac1ca7cfc2344c1c67f3051ffebfae /zebra/kernel_socket.c
parent109153dde80ff0afde942fca4e23c9df6d2fc803 (diff)
bgpd: ignore NEXT_HOP for MP_REACH_NLRI
RFC 4760 states we SHOULD ignore the NEXT_HOP attribute for BGP Update messages carrying only MP_REACH_NLRI attributes. Thus we should use the Network Address of Next Hop field of the MP_REACH_NLRI as the nexthop. Instead of always looking for BGP_ATTR_NEXT_HOP, this commit ensures: 1) we set mp_nexthop_len to BGP_ATTR_NHLEN_IPV4 for v4 bgp_static routes 2) we check mp_nexthop_len when choosing the nexthop to use for nht 3) we check mp_nexthop_len when choosing the nexthop to send to zebra 4) we check mp_nexthop_len when picking the nexthop to shown by vtysh Reported-by: Binon Gorbutt <binon@aervivo.com> Signed-off-by: Trey Aspelund <taspelund@nvidia.com>
Diffstat (limited to 'zebra/kernel_socket.c')
0 files changed, 0 insertions, 0 deletions