Repository navigation
fix(codex): expose sandbox shell tools for ssh backends - #83667
Conversation
|
Codex review: needs maintainer review before merge. Workflow note: Future ClawSweeper reviews update this same comment in place. How this review workflow works
Summary Reproducibility: yes. by source inspection: current main filters PR rating What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. PR egg Rarity: ✨ glimmer. What is this egg doing here?
Real behavior proof Risk before merge Maintainer options:
Next step before merge Security Review detailsBest possible solution: Land the focused namespaced sandbox-shell bridge if maintainers accept the recorded SSH sandbox proof and the guarded non-Docker exposure model. Do we have a high-confidence way to reproduce the issue? Yes by source inspection: current main filters Is this the best way to solve the issue? Yes. The patch avoids restoring the broad retired compatibility profile and instead adds explicit namespaced shell tools only for enabled non-Docker sandbox backends while preserving Codex-native workspace tools. Label justifications:
What I checked:
Likely related people:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 4af590a5f88e. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f27b4de7be
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| normalized === "exec" || | ||
| normalized === "sandbox_exec" || | ||
| normalized === "process" || | ||
| normalized === "sandbox_process" |
There was a problem hiding this comment.
Keep sandbox_exec available when only process is excluded
isSandboxShellDynamicToolExcluded treats any exclusion of process/sandbox_process as a reason to suppress both sandbox shell tools, so a config like codexDynamicToolsExclude: ["process"] unintentionally removes sandbox_exec too. This is broader than the documented “omit these tool names” behavior and breaks the common case where operators want foreground shell access but no process-session management; for non-Docker backends that means no sandbox shell path is exposed at all.
Useful? React with 👍 / 👎.
Fixes #80322.
Summary:
sandbox_execandsandbox_processonly when a non-Docker sandbox backend is active.read/write/edit/apply_patchstay hidden from OpenClaw dynamic tools.codexDynamicToolsExcludeand runtimetoolsAllowbehavior, includingexec/processaliases for the new namespaced sandbox tools.Verification:
node scripts/run-vitest.mjs extensions/codex/src/app-server/run-attempt.test.ts-> 172 tests passed.pnpm -s check:changedthrough Blacksmith Testbox via Crabbox ->tbx_01krxs3kt1znkvjat55a4rz2bw, Actions run https://github.com/openclaw/openclaw/actions/runs/26041124573, exit 0.pnpm buildthrough Blacksmith Testbox via Crabbox ->tbx_01krxsdk63tvrn0n6b4a080etk, Actions run https://github.com/openclaw/openclaw/actions/runs/26041431959, exit 0.AUTOREVIEW_AUTO_TESTS=0 AUTOREVIEW_OPENCLAW_MAINTAINER_VALIDATION=1 .agents/skills/autoreview/scripts/autoreview --mode branch --reviewer codex --fallback-reviewer none-> clean, no accepted/actionable findings.cbx_7582df12c8d0/ runrun_0c68f2e8b5c2, hydrated by Actions run https://github.com/openclaw/openclaw/actions/runs/26042017213, exit 0.Behavior addressed: Codex app-server sessions using OpenClaw SSH sandbox routing can now reach an OpenClaw-provided shell without shadowing Codex native shell.
Real environment tested: AWS Crabbox
cbx_7582df12c8d0with Docker-hosted SSH target, env-backed liveOPENAI_API_KEY, Codex app-server runtime, modelopenai/gpt-5.5.Exact steps or command run after this patch: Created an isolated OpenClaw config with
agents.defaults.sandbox.backend="ssh",tools.exec.host="sandbox",codexDynamicToolsLoading="direct", and an env-backedopenai-codexauth profile, then rannode dist/entry.js agent --local --agent main --model openai/gpt-5.5 --message "Use ... sandbox_exec ... cat /home/sandbox/remote-only.txt ..." --thinking off --json.Evidence after fix: The model replied
OPENCLAW_SANDBOX_EXEC_SSH_OK_1779118303-25670; the test found a Codex app-server binding file and 8 session artifact hits containingsandbox_execor the marker.Observed result after fix: The live Codex agent used the sandbox-routed OpenClaw dynamic tool path to read a marker that existed only inside the SSH target container, and the run exited 0.
What was not tested: Full suite and a separate live Docker-backend negative run; Docker/no-sandbox behavior is covered by focused regression tests.