android_kernel_samsung_a7y1.../net/ipv6
Torsten Hilbrich cdd14f25b1 vti6: Fix memory leak of skb if input policy check fails
commit 2a9de3af21aa8c31cd68b0b39330d69f8c1e59df upstream.

The vti6_rcv function performs some tests on the retrieved tunnel
including checking the IP protocol, the XFRM input policy, the
source and destination address.

In all but one places the skb is released in the error case. When
the input policy check fails the network packet is leaked.

Using the same goto-label discard in this case to fix this problem.

Fixes: ed1efb2aefbb ("ipv6: Add support for IPsec virtual tunnel interfaces")
Signed-off-by: Torsten Hilbrich <torsten.hilbrich@secunet.com>
Reviewed-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-07 14:24:31 +02:00
..
netfilter
addrconf_core.c
addrconf.c
addrlabel.c
af_inet6.c
ah6.c
anycast.c
datagram.c
esp6.c
exthdrs_core.c
exthdrs_offload.c
exthdrs.c
fib6_rules.c
icmp.c
ila.c
inet6_connection_sock.c
inet6_hashtables.c
ip6_checksum.c
ip6_fib.c ipv6: Fix route replacement with dev-only route 2020-04-07 14:04:34 +02:00
ip6_flowlabel.c ipv6: flowlabel: fl6_sock_lookup() must use atomic_inc_not_zero 2020-04-06 19:03:40 +02:00
ip6_gre.c
ip6_icmp.c
ip6_input.c ipv6: drop incoming packets having a v4mapped source address 2020-04-07 08:07:05 +02:00
ip6_offload.c
ip6_offload.h
ip6_output.c ipv6: Fix dangling pointer when ipv6 fragment 2020-04-06 15:07:32 +02:00
ip6_tunnel.c ip6_tunnel: Match to ARPHRD_TUNNEL6 for dev type 2020-04-06 15:08:11 +02:00
ip6_udp_tunnel.c
ip6_vti.c vti6: Fix memory leak of skb if input policy check fails 2020-04-07 14:24:31 +02:00
ip6mr.c ipv6: check sk sk_type and protocol early in ip_mroute_set/getsockopt 2020-04-06 20:26:00 +02:00
ipcomp6.c
ipv6_sockglue.c ipv6: restrict IPV6_ADDRFORM operation 2020-04-07 14:11:59 +02:00
Kconfig
Makefile
mcast_snoop.c
mcast.c ipv6: fix a potential deadlock in do_ipv6_setsockopt() 2020-04-06 16:43:14 +02:00
mip6.c
ndisc.c
netfilter.c
output_core.c inet: switch IP ID generator to siphash 2020-04-06 21:32:45 +02:00
ping.c ipv6: Fix the link time qualifier of 'ping_v6_proc_exit_net()' 2020-04-06 21:35:13 +02:00
proc.c
protocol.c
raw.c ipv6: Consider sk_bound_dev_if when binding a raw socket to an address 2020-04-06 18:20:37 +02:00
reassembly.c inet: frags: call inet_frags_fini() after unregister_pernet_subsys() 2020-04-07 13:42:09 +02:00
route.c ipv6: Fix nlmsg_flags when splitting a multipath route 2020-04-07 14:04:32 +02:00
sit.c vrf: sit mtu should not be updated when vrf netdev is the link 2020-04-06 17:01:39 +02:00
syncookies.c
sysctl_net_ipv6.c
tcp_ipv6.c
tcpv6_offload.c
tunnel6.c
udp_impl.h
udp_offload.c
udp.c
udplite.c
xfrm6_input.c
xfrm6_mode_beet.c
xfrm6_mode_ro.c
xfrm6_mode_transport.c
xfrm6_mode_tunnel.c
xfrm6_output.c
xfrm6_policy.c
xfrm6_protocol.c
xfrm6_state.c
xfrm6_tunnel.c xfrm6_tunnel: Fix potential panic when unloading xfrm6_tunnel module 2020-04-06 18:14:31 +02:00