DeepSeek Harness Sandbox vs Approval: Who Stops First?
Sandbox and approval are two different gates: the sandbox limits what an executor can reach, while approval asks whether to attempt the operation. DeepSeek Harness puts the sandbox at the executor layer and approval in the permission policy (source). Confusing them turns “I approved but the write failed” into a false bug report.
DeepSeek Harness: Two gate positions
Approval happens before execution; the sandbox applies during execution. The order (source):
| Gate | Position | Job | Failure looks like |
|---|---|---|---|
| Approval | Tool pipeline | Ask whether to allow | Prompt, rejection, cancel |
| Sandbox | Executor | Limit what the process can reach | Command failure, permission error |
Approval is “does the human agree”; the sandbox is “does the system allow.” A human yes does not override a system no; a system yes does not remove the human question.
This explains two symptoms: a command still fails after approval because the sandbox blocked it; a command fails without a prompt because the sandbox rejected it directly.
Do not treat them as alternatives. They stack: approval grants an attempt, not a bypass.
DeepSeek Harness: The sandbox: the executor's hard boundary
The sandbox is the last hard boundary and does not read user approval. It checks the current policy for path, process, and network access (source).
Three common limits:
- Path scope — reads and writes only under the workspace or a configured root.
- Process capability — child processes, signals, or system calls.
- Network access — external connections or proxies.
Sandbox failures usually appear as command errors, permission denials, or unwritable files, not approval prompts. For these, check policy and path rather than clicking allow again.
The sandbox also interacts with OS ACLs, containers, and Windows integrity levels. The symptom is “the policy allows it but it still fails”; check the platform layer, not only DeepSeek Harness config.
DeepSeek Harness: Approval: the tool-pipeline question
Approval happens in the tool pipeline and asks according to the current policy. When an operation needs confirmation, the Web UI asks first (source).
Results include allow-once, reject, cancel, and unavailable; they affect whether the agent continues but do not change the sandbox boundary (source).
Approval fits “the human should know”: out-of-scope writes, sensitive commands, system-level changes. Its value is informed consent, not hard enforcement.
Approval is not a sandbox substitute. Asking about everything is tiring and unsafe; the sandbox owns the hard boundary, approval owns awareness and choice.
DeepSeek Harness: Three outcomes
An out-of-scope write has three outcomes, each at a different layer. Compare (source):
- Approval prompt — the tool pipeline asks; allow continues, reject makes the agent switch or stop.
- Direct rejection — the sandbox or policy refuses with no prompt; a permission error appears.
- Command failure — approved and executed, but the OS or filesystem refuses; a write error appears.
The first is “human blocked”; the second “system blocked”; the third “environment blocked.” Debug directions differ.
A prompt calls for allow/reject; a direct rejection calls for preset and sandbox checks; a command failure calls for path, ACL, and platform checks.
They can chain: approve, get rejected by the sandbox, then fail at the OS. Passing the first gate does not prove the later ones.
DeepSeek Harness: Permission presets
The preset decides which gate acts earlier. Default workspace-write keeps writes inside the workspace and uses ask; danger-full-access widens writes and usually uses never (source).
| Preset | Write scope | Approval | Out-of-scope |
|---|---|---|---|
| workspace-write | Inside workspace | ask | May prompt or be sandbox-blocked |
| danger-full-access | Wider | never | Fewer prompts, still OS-limited |
Changing the preset changes a combination, not “all limits off.” danger-full-access removes approval, not the sandbox or the OS.
Choose by asking two questions: where do I need to write, and how often do I want to be asked? Answer both before switching.
DeepSeek Harness: Three gate checks
Use three out-of-scope experiments. Three steps (source):
- Inside the workspace — write succeeds, with or without a prompt per preset.
- Outside the workspace — observe whether it prompts, rejects directly, or fails at the command.
- Approve and retry — approve an out-of-scope operation; confirm whether the sandbox still blocks and whether the error is explainable.
All three mean the order of approval and sandbox matches expectation. Passing only the first often means the preset is too wide; passing the first two often means approval was mistaken for a sandbox bypass.
The existing dsh-sandbox-modes covers sandbox modes, configure-permission-approval covers approval config, and develop-sandbox-argv-policy covers argv policy; this article covers the order of the two gates. See who is blocking before discussing how to allow.
Approval says “you may try”; the sandbox says “the system may execute.” Both must pass for a write to land.
Identify the blocking layer first; allow buttons cannot open a sandbox boundary.
FAQ
DeepSeek Harness does not work that way. The DeepSeek Harness sandbox limits what an executor can reach; approval asks the user whether to attempt an operation. They sit at different layers and can act in sequence.
In DeepSeek Harness, it depends on the operation and preset. DeepSeek Harness may ask at the tool pipeline or reject at the executor; the same write can behave differently under another preset.
DeepSeek Harness supports that. DeepSeek Harness approval permits an attempt; it does not change the sandbox boundary. If the executor still disallows the path, the write fails.
DeepSeek Harness does not work that way. DeepSeek Harness danger-full-access widens the write scope and approval, but OS permissions, the filesystem, and the executor can still block an operation.
Related Terms
- sandbox
- A sandbox is the DeepSeek Harness executor-layer boundary that limits file, process, and network access.— DeepSeek Harness reference - Sandbox
- approval
- Approval is the DeepSeek Harness tool-pipeline mechanism that asks the user whether to allow an operation under the current policy.— DeepSeek Harness docs - Approvals
- permission preset
- A permission preset bundles a writable scope and approval policy in DeepSeek Harness, with workspace-write and danger-full-access as defaults.— DeepSeek Harness docs - Permission presets
- executor
- An executor is the DeepSeek Harness backend that actually starts a process or performs an operation, where sandbox policy applies.— DeepSeek Harness reference - Sandbox
Sources
- DeepSeek Harness reference - Sandbox· deepseek-harness
- DeepSeek Harness docs - Approvals· deepseek-ai
- DeepSeek Harness docs - Permission presets· deepseek-ai