]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ipv4/igmp: Don't drop IGMP pkt with zeros src addr
authorEdward Chron <echron@arista.com>
Thu, 31 Jan 2019 23:00:40 +0000 (15:00 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 3 Feb 2019 17:54:05 +0000 (09:54 -0800)
Don't drop IGMP packets with a source address of all zeros which are
IGMP proxy reports. This is documented in Section 2.1.1 IGMP
Forwarding Rules of RFC 4541 IGMP and MLD Snooping Switches
Considerations.

Signed-off-by: Edward Chron <echron@arista.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/route.c

index 99be68b15da0739b811622654bb20ff07fa08a72..16259ea9df54973e6f5290afd1a415e7de71d5e1 100644 (file)
@@ -1608,7 +1608,8 @@ int ip_mc_validate_source(struct sk_buff *skb, __be32 daddr, __be32 saddr,
                return -EINVAL;
 
        if (ipv4_is_zeronet(saddr)) {
-               if (!ipv4_is_local_multicast(daddr))
+               if (!ipv4_is_local_multicast(daddr) &&
+                   ip_hdr(skb)->protocol != IPPROTO_IGMP)
                        return -EINVAL;
        } else {
                err = fib_validate_source(skb, saddr, 0, tos, 0, dev,