feat(sandbox): add session sandbox controls - #11628
Merged
Merged
Conversation
1 task
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Files Reviewed (38 files)
Reviewed by gpt-5.4-20260305 · Input: 253.9K · Output: 20.7K · Cached: 1.9M Review guidance: REVIEW.md from base branch |
eshurakov
approved these changes
Jun 24, 2026
t7tran
pushed a commit
to t7tran/kilocode
that referenced
this pull request
Aug 14, 2026
feat(sandbox): add session sandbox controls
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.
Sandboxing can currently only be controlled through persistent configuration, so changing it affects every session and clients have no reliable way to show or change the effective runtime state. This is especially confusing when a persisted default remains active without a visible control.
This adds a session-local sandbox override on top of the persistent
experimental.sandboxdefault. The CLI exposes authenticated status and toggle endpoints plus change events, serializes transitions and cleanup per session, keeps overrides isolated by directory, and clears all overrides when a session is removed. Tool and MCP execution use the effective state while preserving the existing filesystem and network policies.The TUI adds
/sandbox, an active-state indicator, and toggle feedback. VS Code adds a feature-gated prompt control that works from an empty composer and Agent Manager worktrees, waits for transitions before sending prompts, fails closed when toggling cannot be confirmed, and reconciles HTTP responses with SSE updates without stale state.Follow-up: #11630