summaryrefslogtreecommitdiff
path: root/net/unix/sysctl_net_unix.c
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2025-01-06 21:01:36 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-01-17 15:41:00 +0300
commitb683ba0df11ff563cc237eb1b74d6adfa77226bf (patch)
tree852f0954e36ab5c6cdf7977cfd587e98ec59b638 /net/unix/sysctl_net_unix.c
parentc08d7fcce7cc01f77087d18cd60f317244436548 (diff)
downloadlinux-b683ba0df11ff563cc237eb1b74d6adfa77226bf.tar.xz
netdev: prevent accessing NAPI instances from another namespace
commit d1cacd74776895f6435941f86a1130e58f6dd226 upstream. The NAPI IDs were not fully exposed to user space prior to the netlink API, so they were never namespaced. The netlink API must ensure that at the very least NAPI instance belongs to the same netns as the owner of the genl sock. napi_by_id() can become static now, but it needs to move because of dev_get_by_napi_id(). Cc: stable@vger.kernel.org Fixes: 1287c1ae0fc2 ("netdev-genl: Support setting per-NAPI config values") Fixes: 27f91aaf49b3 ("netdev-genl: Add netlink framework functions for napi") Reviewed-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Reviewed-by: Joe Damato <jdamato@fastly.com> Link: https://patch.msgid.link/20250106180137.1861472-1-kuba@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/unix/sysctl_net_unix.c')
0 files changed, 0 insertions, 0 deletions