Re: [PATCH 1/5] ptrace: add PTRACE_SYSCALL_INFO_SECCOMP_SKIP

From: Renzo Davoli

Date: Thu Jul 02 2026 - 12:12:07 EST


On Thu, Jul 02, 2026 at 04:47:08PM +0200, Oleg Nesterov wrote:
> On 07/02, Oleg Nesterov wrote:
> Wdyt about something like below?

I like it.

I have one comment:
> + if (ptrace_get_syscall_info_op(child) != info.op) {
> + if (info.op != PTRACE_SYSCALL_INFO_EXIT)
> + return -EINVAL;
> + force = true;
> + }

I have found the behavior "negative syscall number => skip syscall" defined
only for PTRACE_EVENT_SECCOMP in the manual. I'd restrict the option to this
case, for safety.

A minimal detail: I'd also rename "force" into "skip" or "skip_syscall", just
for the sake of readability.

Dmitry: does this proposal have counter effects for strace?

renzo