]> git.proxmox.com Git - pve-kernel.git/blame - CVE-2017-9076_9077-ipv6-dccp-do-not-inherit-ipv6_mc_list-from-parent.patch
bump version to 4.10.15-13
[pve-kernel.git] / CVE-2017-9076_9077-ipv6-dccp-do-not-inherit-ipv6_mc_list-from-parent.patch
CommitLineData
0f831b3c
FG
1From ef8ae9e80ab0846763c6405968852e19c9a87782 Mon Sep 17 00:00:00 2001
2From: WANG Cong <xiyou.wangcong@gmail.com>
3Date: Wed, 7 Jun 2017 12:28:27 +0200
4Subject: [PATCH] ipv6/dccp: do not inherit ipv6_mc_list from parent
5MIME-Version: 1.0
6Content-Type: text/plain; charset=UTF-8
7Content-Transfer-Encoding: 8bit
8
9Like commit 657831ffc38e ("dccp/tcp: do not inherit mc_list from parent")
10we should clear ipv6_mc_list etc. for IPv6 sockets too.
11
12Cc: Eric Dumazet <edumazet@google.com>
13Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
14Acked-by: Eric Dumazet <edumazet@google.com>
15Signed-off-by: David S. Miller <davem@davemloft.net>
16
17CVE-2017-9076
18CVE-2017-9077
19
20(cherry-picked from 83eaddab4378db256d00d295bda6ca997cd13a52)
21Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
22Acked-by: Colin Ian King <colin.king@canonical.com>
23Acked-by: Andy Whitcroft <apw@canonical.com>
24Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
25
26Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
27---
28 net/dccp/ipv6.c | 6 ++++++
29 net/ipv6/tcp_ipv6.c | 2 ++
30 2 files changed, 8 insertions(+)
31
32diff --git a/net/dccp/ipv6.c b/net/dccp/ipv6.c
33index 2f3e8bbe2cb9..8f41327c1edf 100644
34--- a/net/dccp/ipv6.c
35+++ b/net/dccp/ipv6.c
36@@ -426,6 +426,9 @@ static struct sock *dccp_v6_request_recv_sock(const struct sock *sk,
37 newsk->sk_backlog_rcv = dccp_v4_do_rcv;
38 newnp->pktoptions = NULL;
39 newnp->opt = NULL;
40+ newnp->ipv6_mc_list = NULL;
41+ newnp->ipv6_ac_list = NULL;
42+ newnp->ipv6_fl_list = NULL;
43 newnp->mcast_oif = inet6_iif(skb);
44 newnp->mcast_hops = ipv6_hdr(skb)->hop_limit;
45
46@@ -490,6 +493,9 @@ static struct sock *dccp_v6_request_recv_sock(const struct sock *sk,
47 /* Clone RX bits */
48 newnp->rxopt.all = np->rxopt.all;
49
50+ newnp->ipv6_mc_list = NULL;
51+ newnp->ipv6_ac_list = NULL;
52+ newnp->ipv6_fl_list = NULL;
53 newnp->pktoptions = NULL;
54 newnp->opt = NULL;
55 newnp->mcast_oif = inet6_iif(skb);
56diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
57index cfc232714139..c0ca1218801b 100644
58--- a/net/ipv6/tcp_ipv6.c
59+++ b/net/ipv6/tcp_ipv6.c
60@@ -1055,6 +1055,7 @@ static struct sock *tcp_v6_syn_recv_sock(const struct sock *sk, struct sk_buff *
61 newtp->af_specific = &tcp_sock_ipv6_mapped_specific;
62 #endif
63
64+ newnp->ipv6_mc_list = NULL;
65 newnp->ipv6_ac_list = NULL;
66 newnp->ipv6_fl_list = NULL;
67 newnp->pktoptions = NULL;
68@@ -1124,6 +1125,7 @@ static struct sock *tcp_v6_syn_recv_sock(const struct sock *sk, struct sk_buff *
69 First: no IPv4 options.
70 */
71 newinet->inet_opt = NULL;
72+ newnp->ipv6_mc_list = NULL;
73 newnp->ipv6_ac_list = NULL;
74 newnp->ipv6_fl_list = NULL;
75
76--
772.11.0
78