From e5ef61bea6480fa8426fd885476b22bfde210fa0 Mon Sep 17 00:00:00 2001 From: bms Date: Mon, 25 Sep 2006 11:53:54 +0000 Subject: Fix an incompatibility between CARP and IPv4 multicast routing, whereby the VRRPv2 advertisements will originate from the wrong source address. This only affects kernels compiled with MROUTING and after the MRT_INIT ioctl() has been issued. Set imo_multicast_vif in carp's softc to the invalid value -1 after it is zeroed by softc allocation, to stop the ip_output() path looking up the incorrect source address thinking a vif is set. PR: kern/100532 Submitted by: Bohus Plucinsky MFC after: 1 week --- sys/netinet/ip_carp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c index 48c85e0..5e35a8d 100644 --- a/sys/netinet/ip_carp.c +++ b/sys/netinet/ip_carp.c @@ -379,6 +379,7 @@ carp_clone_create(struct if_clone *ifc, int unit, caddr_t params) (sizeof(struct in_multi *) * IP_MIN_MEMBERSHIPS), M_CARP, M_WAITOK); sc->sc_imo.imo_max_memberships = IP_MIN_MEMBERSHIPS; + sc->sc_imo.imo_multicast_vif = -1; callout_init(&sc->sc_ad_tmo, NET_CALLOUT_MPSAFE); callout_init(&sc->sc_md_tmo, NET_CALLOUT_MPSAFE); -- cgit v1.1