erspan: return PACKET_REJECT when the appropriate tunnel is not found
authorHaishuang Yan <yanhaishuang@cmss.chinamobile.com>
Mon, 10 Sep 2018 14:19:47 +0000 (22:19 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 26 Sep 2018 06:37:58 +0000 (08:37 +0200)
commit1beb52cea6cbfe24137587087e7818b620324714
tree827af3e6e60379789d7f8eced36bb1b4539a80f4
parent456191a8554ac6a16d6f497d1bf64d53ca173a68
erspan: return PACKET_REJECT when the appropriate tunnel is not found

[ Upstream commit 5a64506b5c2c3cdb29d817723205330378075448 ]

If erspan tunnel hasn't been established, we'd better send icmp port
unreachable message after receive erspan packets.

Fixes: 84e54fe0a5ea ("gre: introduce native tunnel support for ERSPAN")
Cc: William Tu <u9012063@gmail.com>
Signed-off-by: Haishuang Yan <yanhaishuang@cmss.chinamobile.com>
Acked-by: William Tu <u9012063@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv4/ip_gre.c