Skip to content

fix(jail): explicitly mark all non-stdio fds as close-on-exec - #194

Merged
bleggett merged 1 commit into
edera-dev:mainfrom
bleggett:bleggett/force-close-fds
Oct 26, 2026
Merged

bleggett merged 1 commit into
edera-dev:mainfrom
bleggett:bleggett/force-close-fds

Conversation

@bleggett

Copy link
Copy Markdown
Contributor

All this does is add a safetycheck and mark all fds > stdio as close-on-exec before doing the execvpe by default, so none leak into the jail.

Also adds a preserve_fds config + CLI flag to styrojail, in case you explicitly want to preserve specific FDs across the exec, much like runc does.

@bleggett
bleggett merged commit 613fd81 into edera-dev:main Oct 26, 2026
10 checks passed
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.

3 participants