Repository navigation
fix(exec): require approval for abbreviated inline eval flags [AI] - #116529
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed July 30, 2026, 5:13 PM ET / 21:13 UTC. ClawSweeper reviewWhat this changesThe PR teaches strict inline-evaluation detection to recognize uniquely abbreviated GNU Merge readiness⛔ Blocked until stronger real behavior proof is added - 5 items remain Keep this PR open for maintainer handling. The narrow detector change appears consistent with strict inline-eval’s existing approval boundary and the contributor supplied useful real GNU Priority: P1 Review scores
Verification
How this fits togetherThe node execution host evaluates a requested command against its allowlist and approval policy before any subprocess starts. With flowchart LR
A[Agent command request] --> B[Node execution host]
B --> C[Allowlist and policy analysis]
C --> D[Inline-evaluation detector]
D --> E{Inline code carrier found?}
E -->|Yes| F[Explicit approval required]
E -->|No| G[Execute approved subprocess]
F --> H[Visible denial or approval result]
G --> H
Decision needed
Why: The code intentionally expands strict-mode interception for a historical GNU Awk spelling that current GNU Awk rejects as ambiguous; choosing the supported-version and compatibility boundary is an execution-security policy decision, not merely mechanical follow-up. Before merge
Agent review detailsSecurityNone. PR surfaceSource +6, Tests +28. Total +34 across 3 files. View PR surface stats
Review metricsNone. Merge-risk optionsMaintainer options:
Copy recommended automerge instructionTechnical reviewBest possible solution: Retain the shared detector-based fix, then add final-head proof that an older GNU Awk accepting Do we have a high-confidence way to reproduce the issue? Yes for the current Is this the best way to solve the issue? Unclear: extending the existing shared abbreviation matcher is the narrowest owner-boundary fix, but the historical AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against b7bfe21348c2. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
History |
Current-head behavior proofHead: Environment: AWS Crabbox lease Denied scenario:
Positive control:
Commands and results: Gap: the final subprocess call is instrumented by the node-host test so denial can be proved without running an unsafe payload. GNU option parsing itself was exercised against the real binaries. This path does not involve a channel, native client, browser, or external provider. |
Current-head behavior proofHead: Environment: trusted local checkout using the production node-host adapter, GNU Awk 3.1.8 compiled from the official GNU archive, installed GNU Awk 5.1.0, GNU Make 4.3, and Node 24.15.0. Denied scenario:
Positive control:
Commands and results: Gap: the final subprocess call is instrumented by the node-host test so denial can be proved without running an unsafe payload. GNU option parsing itself was exercised against real old and current binaries. The AWS refresh could not acquire a broker lease after a safe retry ( |
ClawSweeper reviewReviewed July 30, 2026, 9:51 PM UTC. What this changesThe PR makes strict inline-evaluation approval recognize abbreviated GNU Awk PR surface: Source +6, Tests +28. Total +34 across 3 files. Merge readinessResult: needs maintainer review before merge. Overall: 🦞 diamond lobster Reviewed head: Review scores
VerificationStatus: sufficient How this fits togetherOpenClaw analyzes agent exec requests before an allowlisted process may run. Inline-evaluation findings feed the node-host and gateway approval paths, which either require explicit approval or permit the approved subprocess. flowchart LR
A[Agent exec request] --> B[Command segment analysis]
B --> C[Interpreter option detector]
C --> D{Inline program?}
D -->|Yes| E[Strict approval boundary]
D -->|No| F[Normal allowlist policy]
E --> G[Approval or denial result]
F --> H[Approved subprocess]
Decision needed
Before merge
Review detailsBest possible solution: Keep proven GNU abbreviation floors in the shared detector, preserve benign file-based execution, and ship the final-head boundary coverage so every node-host and gateway caller enforces the same rule. Do we have a high-confidence way to reproduce the issue? Yes. Current main and v2026.7.1 omit abbreviation matching while real GNU binaries execute Is this the best way to solve the issue? Yes. Extending the established per-interpreter specifications at the shared detector covers node-host and gateway callers without duplicated policy; probing executable versions during requests would violate the hot-path boundary and still mishandle aliases. AGENTS.md: found_applied Codex review notes: model internal, reasoning high; reviewed against 0723190. Label detailsLabel justifications:
Evidence reviewedPR surface:
|
Verification before mergeVerified head:
GitHub reports the PR as mergeable. No actionable source, test, CI, or proof findings remain. |
* repair/pr-111802-preserve: (3263 commits) test: type session request parameters (openclaw#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (openclaw#116529) fix: keep owner-only tools out of non-owner skill commands [AI] (openclaw#116532) fix(ui): bound Talk relay microphone uplink fix(tui): require a fresh agent roster (openclaw#116715) fix(memory-wiki): preserve user edits when rolling back ChatGPT imports (openclaw#116517) fix(agents): cron failures preserve timeout and cancellation reasons (openclaw#116566) fix(release): unblock beta validation workflows (openclaw#116708) fix(ci): discover frozen target startup benchmark cases (openclaw#116711) fix(session): preserve reset message payloads (openclaw#116195) fix(qa): tolerate loaded-runner bus delivery stalls (openclaw#116448) improve(ci): rebalance embedded agent test configs (openclaw#116436) fix(browser): return committed trace path (openclaw#116702) fix(qa): exceed Slack table aggregate limit in fallback probe (openclaw#116447) fix(qa): use built plugin tools server (openclaw#116442) fix(test): keep memory FD repro config valid (openclaw#116698) fix(telegram): keep queued tool progress in one message (openclaw#116685) ...
* preserve/pr-109971-ollama-show-inspection-20260731: (4302 commits) fix(agents): resume interrupted turns past progress commentary (openclaw#116725) fix(gateway): sign device proofs with challenge time (openclaw#116679) fix(testing): load relay smoke through UI Vite config test(testing): guard realtime relay smoke module path fix(testing): repair realtime relay live smoke import test: type session request parameters (openclaw#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (openclaw#116529) fix: keep owner-only tools out of non-owner skill commands [AI] (openclaw#116532) fix(ui): bound Talk relay microphone uplink fix(tui): require a fresh agent roster (openclaw#116715) fix(memory-wiki): preserve user edits when rolling back ChatGPT imports (openclaw#116517) fix(agents): cron failures preserve timeout and cancellation reasons (openclaw#116566) fix(release): unblock beta validation workflows (openclaw#116708) fix(ci): discover frozen target startup benchmark cases (openclaw#116711) fix(session): preserve reset message payloads (openclaw#116195) fix(qa): tolerate loaded-runner bus delivery stalls (openclaw#116448) improve(ci): rebalance embedded agent test configs (openclaw#116436) ...
* preserve/pr-107473-ollama-stream-ndjson-cap: (5598 commits) chore(changelog): remove release-owned entry fix(agents): resume interrupted turns past progress commentary (openclaw#116725) fix(gateway): sign device proofs with challenge time (openclaw#116679) fix(testing): load relay smoke through UI Vite config test(testing): guard realtime relay smoke module path fix(testing): repair realtime relay live smoke import test: type session request parameters (openclaw#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (openclaw#116529) fix: keep owner-only tools out of non-owner skill commands [AI] (openclaw#116532) fix(ui): bound Talk relay microphone uplink fix(tui): require a fresh agent roster (openclaw#116715) fix(memory-wiki): preserve user edits when rolling back ChatGPT imports (openclaw#116517) fix(agents): cron failures preserve timeout and cancellation reasons (openclaw#116566) fix(release): unblock beta validation workflows (openclaw#116708) fix(ci): discover frozen target startup benchmark cases (openclaw#116711) fix(session): preserve reset message payloads (openclaw#116195) fix(qa): tolerate loaded-runner bus delivery stalls (openclaw#116448) ...
…-supported-paths * origin/main: (115 commits) test: type session request parameters (#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (#116529) fix: keep owner-only tools out of non-owner skill commands [AI] (#116532) fix(tui): require a fresh agent roster (#116715) fix(memory-wiki): preserve user edits when rolling back ChatGPT imports (#116517) fix(agents): cron failures preserve timeout and cancellation reasons (#116566) fix(release): unblock beta validation workflows (#116708) fix(ci): discover frozen target startup benchmark cases (#116711) fix(session): preserve reset message payloads (#116195) fix(qa): tolerate loaded-runner bus delivery stalls (#116448) improve(ci): rebalance embedded agent test configs (#116436) fix(browser): return committed trace path (#116702) fix(qa): exceed Slack table aggregate limit in fallback probe (#116447) fix(qa): use built plugin tools server (#116442) fix(test): keep memory FD repro config valid (#116698) fix(telegram): keep queued tool progress in one message (#116685) fix(qa): stop waiting on yielded fanout runs (#116440) ... # Conflicts: # src/system-agent/setup-inference-detect.ts # ui/src/e2e/model-setup.e2e.test.ts
* origin/main: (1976 commits) fix(ollama): models advertise tools when /api/show fails (openclaw#109971) fix(ollama): use CJK-aware char estimate for usage fallback (openclaw#110073) fix(ollama): release failed setup response bodies before returning (openclaw#111802) feat(plugins): externalize Synthetic provider (openclaw#116720) fix(agents): unblock channel turns after restart recovery (openclaw#116728) fix(telegram): keep typing alive during active steered tasks (openclaw#116721) fix(gateway): admit standalone MCP app work (openclaw#116727) fix(googlechat): record canonical receipt thread (openclaw#116717) test(ui): cover the Talk relay start-stop race fix(ui): close superseded Talk allocations fix(agents): resume interrupted turns past progress commentary (openclaw#116725) fix(gateway): sign device proofs with challenge time (openclaw#116679) fix(testing): load relay smoke through UI Vite config test(testing): guard realtime relay smoke module path fix(testing): repair realtime relay live smoke import test: type session request parameters (openclaw#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (openclaw#116529) ...
…penclaw#116529) * fix: gate abbreviated interpreter eval flags * fix(exec): cover legacy gawk source abbreviation
…-supported-paths * origin/main: (115 commits) test: type session request parameters (openclaw#116713) fix: retain event invalidation for pagination docs: note queued session refresh fix fix: preserve queued session refresh options fix(exec): require approval for abbreviated inline eval flags [AI] (openclaw#116529) fix: keep owner-only tools out of non-owner skill commands [AI] (openclaw#116532) fix(tui): require a fresh agent roster (openclaw#116715) fix(memory-wiki): preserve user edits when rolling back ChatGPT imports (openclaw#116517) fix(agents): cron failures preserve timeout and cancellation reasons (openclaw#116566) fix(release): unblock beta validation workflows (openclaw#116708) fix(ci): discover frozen target startup benchmark cases (openclaw#116711) fix(session): preserve reset message payloads (openclaw#116195) fix(qa): tolerate loaded-runner bus delivery stalls (openclaw#116448) improve(ci): rebalance embedded agent test configs (openclaw#116436) fix(browser): return committed trace path (openclaw#116702) fix(qa): exceed Slack table aggregate limit in fallback probe (openclaw#116447) fix(qa): use built plugin tools server (openclaw#116442) fix(test): keep memory FD repro config valid (openclaw#116698) fix(telegram): keep queued tool progress in one message (openclaw#116685) fix(qa): stop waiting on yielded fanout runs (openclaw#116440) ... # Conflicts: # src/system-agent/setup-inference-detect.ts # ui/src/e2e/model-setup.e2e.test.ts
What Problem This Solves
Fixes an issue where operators using
strictInlineEvalcould see abbreviated GNU interpreter options bypass the expected approval prompt whenawkormakewas allowlisted.Why This Change Was Made
The inline-eval detector now records the shortest unambiguous GNU spellings for
--sourceand--evalusing its existing abbreviation matcher. Ambiguous shorter options remain untouched, avoiding false positives for valid option parsing.User Impact
Abbreviated inline programs such as
gawk --so=...andmake --ev=...now require the same approval as their full option names. Normal script-file execution and ambiguous long-option prefixes keep their existing behavior.Evidence
node scripts/run-vitest.mjs src/infra/command-analysis/inline-eval.test.ts— 149 tests passed.node scripts/run-vitest.mjs src/node-host/invoke-system-run.test.ts— 81 tests passed.git diff --checkoxfmt --checkandscripts/run-oxlint.mjschecks passed.AI-assisted change.