]> git.puffer.fish Git - mirror/frr.git/commit
Zebra: Update/fix router_lifetime in IPv6 RAs
authorvivek <vivek@cumulusnetworks.com>
Tue, 3 May 2016 19:10:22 +0000 (12:10 -0700)
committervivek <vivek@cumulusnetworks.com>
Tue, 3 May 2016 19:10:22 +0000 (12:10 -0700)
commit690baa53592320dddee5c729f959150cc9a72699
tree85125d1550349c9df5cfaf455ddb8225348ff6cf
parent825649bd9fc0d44014ddd81bd460ec1f83270884
Zebra: Update/fix router_lifetime in IPv6 RAs

BGP Unnumbered relies on IPv6 Router Advertisements (RAs) to advertise our
link-local IPv6 address and learn of the peer's address in order to initiate
the BGP peering. When IPv6 RAs are enabled on an interface, Quagga currently
advertises a non-zero router lifetime which causes hosts receiving the RAs
to install the router as the default router. This may not be desirable in
many situations - the IPv6 RAs may be turned on just to get BGP unnumbered
peering up.

There is a sysctl available to control the host behavior (net.ipv6.conf.all.
accept_ra_defrtr). However, this requires setting on all hosts and this may
mean many hosts, especially if Quagga is run on the hosts.

An alternate solution arrived at was to modify Quagga to advertise a zero
router lifetime, unless a value is specifically set by the operator. This
patch implements this change. The change may not meet a strict interpretation
of the RFC, so it is under HAVE_CUMULUS. When hosts see an IPv6 RA with a
router lifetime of 0, they won't make that router a default router. The
patch also fixes an incorrect check in handling of received RAs which would
have caused us to drop RAs with a lifetime of 0.

Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
Ticket: CM-9815
Reviewed By: CCR-4611
Testing Done: Manual, bgp-min etc. (defails in defect)
zebra/rtadv.c
zebra/zserv.c
zebra/zserv.h