BGP installing route in RIB even though IPv6 next-hop is not reachable.

Topology:

Cisco--222::11----EBGP---2222::22--R2(Quagga)--3333::22-----IBGP----3333::33---DUT(Quagga)


Steps to reproduce:

1.From Cisco advertise ipv6 network route (say 4444::/64) to R2
2.On R2 we are getting EBGP route and instaled in RIB.
3.Do not configure next-hop self on R2.
4.DUT learns routes advertized by Cisco. Installs in the RIB without nexthop 
reachabilty check.

Debug issue below check is return 1
bgp_nexthop_lookup_ipv6 ()
{
   .....

  if (attr->extra->mp_nexthop_len != 16
     || IN6_IS_ADDR_LINKLOCAL (&attr->extra->mp_nexthop_global))
   return 1;

   .....

}

Here my debug shows attr->extra->mp_nexthop_len is 32 not 16. 
So nexthopt reacabilty return suscess without quering RIB.

Another Observation from From RFC#2545 
section 3:

The link-local address shall be included in the Next Hop field if and
only if the BGP speaker shares a common subnet with the entity
identified by the global IPv6 address carried in the Network Address
of Next Hop field and the peer the route is being advertised to.

The above rule is not respected by quagga and Cisco also. So route is sent to 
peer with next-hop with global
and link-local address making value of the Length of Next Hop Network Address 
field on a MP_REACH_NLRI attribute set to 32


Can anyone suggest fix for this issue.

Regards
Srinivas K

                                          
_______________________________________________
Quagga-dev mailing list
[email protected]
https://lists.quagga.net/mailman/listinfo/quagga-dev

Reply via email to