From d7fc0e677e8c6804e00e770b4bd2c080c7ba028a Mon Sep 17 00:00:00 2001 From: Don Slice Date: Tue, 3 Dec 2019 14:02:20 +0000 Subject: zebra: send RA lifetime of 0 before ceasing to advertise RAs Problem reported by testing agency that RFC4861 section 6.2.5 states that a router should send an RA with a lifetime of 0 before ceasing to send RAs on the interface, or when the interace is shutdown, or the router is shutdown. This fix adds that capability. Ticket: CM-27061 Signed-off-by: Don Slice --- zebra/interface.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'zebra/interface.c') diff --git a/zebra/interface.c b/zebra/interface.c index 20b05dfb32..bcb833b8d8 100644 --- a/zebra/interface.c +++ b/zebra/interface.c @@ -1977,6 +1977,8 @@ DEFUN (shutdown_if, struct zebra_if *if_data; if (ifp->ifindex != IFINDEX_INTERNAL) { + /* send RA lifetime of 0 before stopping. rfc4861/6.2.5 */ + rtadv_stop_ra(ifp); ret = if_unset_flags(ifp, IFF_UP); if (ret < 0) { vty_out(vty, "Can't shutdown interface\n"); -- cgit v1.2.3