feat: enforce execution.{timeout_seconds, require_approval, sandbox}#11
Merged
Conversation
added 2 commits
June 25, 2026 20:27
These were declared config fields read by zero lines (a security-integrity gap the docs over-claimed). FeatureCodeExecutor now enforces them (opt-in params, defaults preserve behavior): - timeout_seconds: SIGALRM wall-clock guard (main-thread); times out runaway code - require_approval: fail-closed HITL gate (runs only if a wired approver grants it) - sandbox: in-process 'monty'/'local' run the restricted executor; 'docker'/'e2b' now FAIL fast instead of silently running in-process pretending to be isolated The GenAI auto-config wires timeout_seconds + sandbox from config.execution. security.md updated: these are now enforced (budget_usd remains roadmap). TDD.
β¦nt control drop) Security-review Finding 1 (fail-open): the auto-config threaded timeout + sandbox from config.execution but silently dropped require_approval, so the documented HITL default was not applied on the wired path. Now the full execution config is wired; with the default require_approval=True and no approver, wired GenAI fail-closes (secure-by-default) β set execution.require_approval=False or wire an approver to run unattended. TDD: asserts the wired executor carries timeout/sandbox/require_approval and fail-closes by default.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Increment 3 (integrity gaps). These
ExecutionConfigfields were declared but read by zero lines β the security docs over-claimed. Now enforced:FeatureExecutionError.monty/localrun the restricted executor;docker/e2bfail fast instead of silently running in-process (so you can't mistake in-process for container isolation).Defaults are unchanged (no timeout, no approval, in-process), so existing code/tests/samples are unaffected. The GenAI auto-config wires
timeout_seconds+sandboxfromconfig.execution.security.mdupdated to match reality (timeout + approval enforced;budget_usdpre-call enforcement remains roadmap).TDD: 5 real enforcement tests (timeout, docker-rejected, in-process-runs, approval allow/deny/fail-closed, defaults-unchanged). Local gates green: ruff/format/pyright/24 tests + strict docs.