Repository navigation
fix: keep inline eval approvals one-shot [AI] - #112956
Conversation
|
ClawSweeper proof for current head 39a64e1 Behavior proved: persistent allow-always approval does not become reusable for interpreter inline program text, while normal file/script-style command paths still classify as intended.
|
|
Codex review: needs maintainer review before merge. Reviewed July 23, 2026, 3:37 PM UTC. Summary PR surface: Source +137, Tests +370. Total +507 across 3 files. Reproducibility: Yes from source inspection: current main lacks these interpreter aliases, and the allow-always persistence path depends on inline-eval detection to keep inline payloads one-shot. I did not run tests because this review is read-only, but the PR body and follow-up comment report focused exact-head validation. Review metrics:
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Risk before merge
Maintainer decision needed
Next step before merge
Security Review detailsBest possible solution: Land the centralized classifier hardening after maintainer/security-owner acceptance of the stricter one-shot approval behavior for the newly covered interpreter forms. Do we have a high-confidence way to reproduce the issue? Yes from source inspection: current main lacks these interpreter aliases, and the allow-always persistence path depends on inline-eval detection to keep inline payloads one-shot. I did not run tests because this review is read-only, but the PR body and follow-up comment report focused exact-head validation. Is this the best way to solve the issue? Yes: the PR extends the existing centralized classifier that feeds approval persistence rather than duplicating policy in callers. The remaining question is owner acceptance of the stricter approval boundary, not a better implementation layer. AGENTS.md: found_applied Codex review notes: model internal, reasoning high; reviewed against 4f4d895. Label detailsLabel justifications:
Evidence reviewedPR surface:
|
|
Verification before merge Current head:
|
…omic-publication-20260724 * origin/main: refactor(memory-lancedb): remove dead legacy path scan (#113299) fix(test): satisfy no-map-spread in exec approvals (#113303) fix: keep OAuth refresh failures terminal [AI] (#112957) fix: reusable exec approvals apply to approved arguments (#112946) refactor(agents): split tool search internals (#113296) fix: keep inline eval approvals one-shot [AI] (#112956) refactor(normalization): reuse trimmed list helpers (#113295) fix(openai): fail fast on invalid TLS certificates (#111818) fix: recognize more shell wrappers [AI] (#112955) fix(i18n): correct Indonesian seconds labels chore(i18n): refresh native locales fix: block opaque exec dispatch wrappers (#112953)
* fix: classify inline eval interpreters * fix: cover inline eval flag variants * fix: handle snippet eval option aliases * fix: classify debugger and runtime callbacks * fix: tighten interpreter eval matching * fix: cover gdb early init eval flags * fix: cover bundled eval option forms * fix: cover gdb eval abbreviations * fix: cover iex and guile eval forms
What Problem This Solves
Fixes an issue where users who chose an always-allow exec approval for some inline interpreter commands could have that approval reused for a later command with different inline code.
Why This Change Was Made
The inline-command classifier now recognizes additional interpreter entry points that evaluate code passed on the command line. This keeps broad persistent approvals from being created for those interpreter invocations while leaving ordinary script execution and existing shell/package-manager behavior unchanged.
User Impact
Users continue to see the normal prompt for changed inline interpreter payloads instead of having a previous broad approval reused. Script-file invocations for these tools can still follow the existing approval paths.
Evidence
node scripts/run-vitest.mjs src/infra/command-analysis/inline-eval.test.ts src/infra/exec-approvals-allow-always.test.tsAI-assisted: yes.