From a399bc519ccf3f749e32a0eabfbb8db46780dd10 Mon Sep 17 00:00:00 2001 From: dongshengyuan <545258830@qq.com> Date: Fri, 7 Aug 2026 13:37:51 +0800 Subject: [PATCH] man: mention openat2 effect of RestrictSUIDSGID RestrictSUIDSGID uses seccomp to block setting SUID/SGID bits. openat2() passes these mode bits indirectly via struct open_how. Document that such calls are blocked regardless of requested mode. Closes #43314 --- man/systemd.exec.xml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/man/systemd.exec.xml b/man/systemd.exec.xml index 0b43bc6960..7561425dc9 100644 --- a/man/systemd.exec.xml +++ b/man/systemd.exec.xml @@ -2818,6 +2818,11 @@ RestrictNamespaces=~cgroup net systemd-system.conf5, which defaults to off. + This setting is implemented using seccomp filtering. For system calls where the mode bits are + passed directly as arguments, the call is denied only when the SUID or SGID bits are set. For system + calls where those bits are passed indirectly and cannot be inspected by the filter, such as + openat2(), the call is blocked entirely, regardless of the requested mode. +