summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorBrendan McGrath <redmcg@redmandi.dyndns.org>2017-12-13 14:14:57 +0300
committerDavid S. Miller <davem@davemloft.net>2017-12-17 06:51:26 +0300
commit588753f1eb18978512b1c9b85fddb457d46f9033 (patch)
tree5b4d007e284c912b34628de1b66e6d237cceb2c0 /net
parentf3b5ad89de16f5d42e8ad36fbdf85f705c1ae051 (diff)
downloadlinux-588753f1eb18978512b1c9b85fddb457d46f9033.tar.xz
ipv6: icmp6: Allow icmp messages to be looped back
One example of when an ICMPv6 packet is required to be looped back is when a host acts as both a Multicast Listener and a Multicast Router. A Multicast Router will listen on address ff02::16 for MLDv2 messages. Currently, MLDv2 messages originating from a Multicast Listener running on the same host as the Multicast Router are not being delivered to the Multicast Router. This is due to dst.input being assigned the default value of dst_discard. This results in the packet being looped back but discarded before being delivered to the Multicast Router. This patch sets dst.input to ip6_input to ensure a looped back packet is delivered to the Multicast Router. Signed-off-by: Brendan McGrath <redmcg@redmandi.dyndns.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/ipv6/route.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 7a8d1500d374..2bc91c349273 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -2336,6 +2336,7 @@ struct dst_entry *icmp6_dst_alloc(struct net_device *dev,
}
rt->dst.flags |= DST_HOST;
+ rt->dst.input = ip6_input;
rt->dst.output = ip6_output;
rt->rt6i_gateway = fl6->daddr;
rt->rt6i_dst.addr = fl6->daddr;