Skip to content

Reject unsupported seccomp errno values - #5559

Closed
sairex53 wants to merge 1 commit into
opencontainers:mainfrom
sairex53:5550-reject-errno-on-allow
Closed

sairex53 wants to merge 1 commit into
opencontainers:mainfrom
sairex53:5550-reject-errno-on-allow

Conversation

@sairex53

Copy link
Copy Markdown
Contributor

Fixes #5550

OCI Runtime Specification requires a runtime to fail when an errno return value is provided for an action that does not support it. runc currently discards defaultErrnoRet and per-syscall errnoRet for SCMP_ACT_ALLOW, so invalid seccomp configurations are accepted.

Reject unsupported action/errno combinations while preserving SCMP_ACT_ERRNO and SCMP_ACT_TRACE. Include coverage for default and per-syscall actions.

Tests:

  • go test -tags seccomp ./libcontainer/seccomp ./libcontainer/specconv

Fixes opencontainers#5550

Assisted-by: Codex GPT-6
Signed-off-by: Eduard Zateev <hackerowskiy@gmail.com>
@kolyshkin

Copy link
Copy Markdown
Contributor

Check is complicated, and is done in runc init which is both late and lame. It can also bring in compatibility issues for older profiles -- have you checked what moby and containers/common profiles have?

@kolyshkin

Copy link
Copy Markdown
Contributor

closing in favor of #5564

@kolyshkin kolyshkin closed this Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

runc accepts errno values for SCMP_ACT_ALLOW

2 participants