ipv6: don't let node/interface scoped multicast traffic escape on the wire
Subsystems (3)
PATCH 1/1 ipv6: don't let node/interface scoped multicast traffic escape on the wire
Reported-by Erik Hugne <[email protected]>
Cc Erik Hugne <[email protected]>
Cc YOSHIFUJI Hideaki <[email protected]>
Signed-off-by Hannes Frederic Sowa <[email protected]>
--- net/ipv6/ip6_output.c | 7 +++++++ 1 file changed, 7 insertions(+)
net/ipv6/ip6_output.c +7 -0
@@ -120,6 +120,13 @@ static int ip6_finish_output2(struct sk_buff *skb)IP6_UPD_PO_STATS (dev_net (dev), idev,IPSTATS_MIB_OUTMCAST , skb->len); + +if (IPV6_ADDR_MC_SCOPE (&ipv6_hdr (skb)->daddr) <= +IPV6_ADDR_SCOPE_NODELOCAL && + !(dev->flags &IFF_LOOPBACK )) { +kfree_skb (skb); +return 0 ; + } }rcu_read_lock_bh ();
Signature · 1 line
1.8.1.2
Quoted 17 lines
Reported-by Erik Hugne <[email protected]>Cc Erik Hugne <[email protected]>Cc YOSHIFUJI Hideaki <[email protected]>Signed-off-by Hannes Frederic Sowa <[email protected]>--- net/ipv6/ip6_output.c | 7 +++++++ 1 file changed, 7 insertions(+)net/ipv6/ip6_output.c +0
-0@@ -120,6 +120,13 @@ static int ip6_finish_output2(struct sk_buff *skb)IP6_UPD_PO_STATS (dev_net (dev), idev,IPSTATS_MIB_OUTMCAST , skb->len);
net/ipv6/ip6_output.c static int ip6_finish_output2(struct sk_buff *skb) · line 132
Quoted 10 lines
net/ipv6/ip6_output.c +7
-0+ +if (IPV6_ADDR_MC_SCOPE (&ipv6_hdr (skb)->daddr) <= +IPV6_ADDR_SCOPE_NODELOCAL && + !(dev->flags &IFF_LOOPBACK )) { +kfree_skb (skb); +return 0 ; + } }rcu_read_lock_bh ();
--yoshfuji
From: Hannes Frederic Sowa <[email protected]>
Date: Sun, 10 Feb 2013 13:33:35 +0100
Quoted 4 lines
Reported-by Erik Hugne <[email protected]>Cc Erik Hugne <[email protected]>Cc YOSHIFUJI Hideaki <[email protected]>Signed-off-by Hannes Frederic Sowa <[email protected]>
Applied.