[PATCH v4 2/3] pidfd: Use scoped cleanup for task access
sashiko-bot at kernel.org
sashiko-bot at kernel.org
Wed Oct 28 08:46:28 UTC 2026
> From: Chen Linxuan <me at black-desk.cn>
>
> Split namespace acquisition from namespace fd creation and represent a
> privileged target task as a scoped class that owns both the task
> reference and exec_update_lock. Use the class for namespace lookups so
> ptrace access checks and task state reads remain tied to the same exec
> critical section, while open_namespace() stays outside the lock.
>
> Carry the pid namespace visibility check into the helper so that all
> users of the class enforce it.
>
> Signed-off-by: Chen Linxuan <me at black-desk.cn>
Sashiko has reviewed this patch and found no issues.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261027-pidfd-get-paths-v4-0-e2a6a47e3c95@black-desk.cn?part=2
More information about the Linux-security-module-archive
mailing list