summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2017-05-17 07:16:40 -0700
committerSiqi Lin <siqilin@google.com>2017-08-15 23:35:41 +0000
commit5f75e3f7f20f605b1e6699d6f8659e39ac704fec (patch)
tree061d25f838e91401a8555174178d7e5beccff2bd
parentaf29ec500fa901cf4c64b730f223dff9ff316b72 (diff)
downloadx86_64-5f75e3f7f20f605b1e6699d6f8659e39ac704fec.tar.gz
UPSTREAM: sctp: do not inherit ipv6_{mc|ac|fl}_list from parent
SCTP needs fixes similar to 83eaddab4378 ("ipv6/dccp: do not inherit ipv6_mc_list from parent"), otherwise bad things can happen. Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: Andrey Konovalov <andreyknvl@google.com> Tested-by: Andrey Konovalov <andreyknvl@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> (cherry picked from commit fdcee2cbb8438702ea1b328fb6e0ac5e9a40c7f8) Signed-off-by: Connor O'Brien <connoro@google.com> Bug: 62298712 Change-Id: I386efa7b8e8a99b22830a9593c92a41232ab03bb
-rw-r--r--net/sctp/ipv6.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/sctp/ipv6.c b/net/sctp/ipv6.c
index 422d8bdacc0d..154a123647eb 100644
--- a/net/sctp/ipv6.c
+++ b/net/sctp/ipv6.c
@@ -657,6 +657,9 @@ static struct sock *sctp_v6_create_accept_sk(struct sock *sk,
newnp = inet6_sk(newsk);
memcpy(newnp, np, sizeof(struct ipv6_pinfo));
+ newnp->ipv6_mc_list = NULL;
+ newnp->ipv6_ac_list = NULL;
+ newnp->ipv6_fl_list = NULL;
/* Initialize sk's sport, dport, rcv_saddr and daddr for getsockname()
* and getpeername().