Skip to content

fix(agent chart): grant SYS_PTRACE so the agent can resolve sandbox PIDs - #74

Merged
bpalermo merged 1 commit into
mainfrom
fix/agent-sys-ptrace-cap
Jun 7, 2026
Merged

bpalermo merged 1 commit into
mainfrom
fix/agent-sys-ptrace-cap

Conversation

@bpalermo

@bpalermo bpalermo commented Jun 7, 2026

Copy link
Copy Markdown
Owner

Resolving a pod's sandbox PID from its netns (for SPIRE SVID subscription) requires following other processes' /proc/<pid>/ns/net magic symlinks, which needs PTRACE_MODE_READ (CAP_SYS_PTRACE). The agent dropped ALL caps and added only NET_ADMIN/DAC_OVERRIDE, so the netns inode scan found no match and SVID subscription failed with no process found owning netns.

Verified live on talos-main: with SYS_PTRACE, the agent resolves the sandbox PID and logs subscribed to SVID after resolving workload PID. Complements #72.

Resolving a pod's sandbox PID from its netns requires following other processes'
/proc/<pid>/ns/net magic symlinks, which needs PTRACE_MODE_READ (CAP_SYS_PTRACE).
The agent dropped ALL capabilities and added only NET_ADMIN/DAC_OVERRIDE, so the
netns inode scan found no match and SVID subscription failed with
"no process found owning netns". Add SYS_PTRACE so the deferred PID resolution
introduced for SPIRE SVID subscription works.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
@bpalermo
bpalermo merged commit 17b5539 into main Jun 7, 2026
10 checks passed
@bpalermo
bpalermo deleted the fix/agent-sys-ptrace-cap branch June 7, 2026 17:33
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.

1 participant