summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2025-02-07 13:58:40 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-02-21 14:01:43 +0100
commit0bf8e2f3768629d437a32cb824149e6e98254381 (patch)
tree762c6410243eda74989097f8abcec18c8c4beace /fs
parent789230e5a8c1097301afc802e242c79bc8835c67 (diff)
downloadlinux-0bf8e2f3768629d437a32cb824149e6e98254381.tar.gz
linux-0bf8e2f3768629d437a32cb824149e6e98254381.tar.bz2
linux-0bf8e2f3768629d437a32cb824149e6e98254381.zip
ipv6: mcast: extend RCU protection in igmp6_send()
[ Upstream commit 087c1faa594fa07a66933d750c0b2610aa1a2946 ] igmp6_send() can be called without RTNL or RCU being held. Extend RCU protection so that we can safely fetch the net pointer and avoid a potential UAF. Note that we no longer can use sock_alloc_send_skb() because ipv6.igmp_sk uses GFP_KERNEL allocations which can sleep. Instead use alloc_skb() and charge the net->ipv6.igmp_sk socket under RCU protection. Fixes: b8ad0cbc58f7 ("[NETNS][IPV6] mcast - handle several network namespace") Signed-off-by: Eric Dumazet <edumazet@google.com> Reviewed-by: David Ahern <dsahern@kernel.org> Reviewed-by: Kuniyuki Iwashima <kuniyu@amazon.com> Link: https://patch.msgid.link/20250207135841.1948589-9-edumazet@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'fs')
0 files changed, 0 insertions, 0 deletions