mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] seccomp: support O_PATH descriptors in addfd
@ 2026-09-24 22:30 Cong Wang
  2026-09-24 22:30 ` [PATCH 1/2] seccomp: allow addfd to transfer O_PATH descriptors Cong Wang
  2026-09-24 22:30 ` [PATCH 2/2] selftests/seccomp: test addfd with an O_PATH descriptor Cong Wang
  0 siblings, 2 replies; 3+ messages in thread
From: Cong Wang @ 2026-09-24 22:30 UTC (permalink / raw)
  To: Andy Lutomirski; +Cc: Kees Cook, linux-kernel, Will Drewry, Christian Brauner

From: Cong Wang <cwang@multikernel.io>

The Sandlock project uses seccomp user notification to broker opens. To
maintain user-space application compatibility, it needs to return a
genuine O_PATH descriptor when an application requests one. Currently,
SECCOMP_IOCTL_NOTIF_ADDFD rejects the supervisor's O_PATH descriptor
with EBADF.

Allow addfd to transfer O_PATH descriptors and add a regression test for
their flags and read behavior. All 112 seccomp functional tests and all
7 benchmark checks passed.

Cong Wang (2):
  seccomp: allow addfd to transfer O_PATH descriptors
  selftests/seccomp: test addfd with an O_PATH descriptor

 kernel/seccomp.c                              |  2 +-
 tools/testing/selftests/seccomp/seccomp_bpf.c | 59 +++++++++++++++++++
 2 files changed, 60 insertions(+), 1 deletion(-)

-- 
2.43.0

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-09-24 22:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-24 22:30 [PATCH 0/2] seccomp: support O_PATH descriptors in addfd Cong Wang
2026-09-24 22:30 ` [PATCH 1/2] seccomp: allow addfd to transfer O_PATH descriptors Cong Wang
2026-09-24 22:30 ` [PATCH 2/2] selftests/seccomp: test addfd with an O_PATH descriptor Cong Wang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®