--- zzzz-none-000/linux-4.4.60/net/sctp/socket.c 2017-04-08 07:53:53.000000000 +0000 +++ hawkeye-5590-729/linux-4.4.60/net/sctp/socket.c 2022-03-30 14:21:53.000000000 +0000 @@ -4419,6 +4419,10 @@ struct socket *sock; int err = 0; + /* Do not peel off from one netns to another one. */ + if (!net_eq(current->nsproxy->net_ns, sock_net(sk))) + return -EINVAL; + if (!asoc) return -EINVAL;