Repository navigation
fix(evals): set aside a denied compound call whose plugin part was then allowed alone - #12373
Conversation
…en allowed alone run-validity counted a denied compound Bash call as a with-arm plugin denial even when a later call in the same run was its plugin-path part alone and was allowed, so a state-saving skill whose model wraps the prescribed script call in assignments, cd or a trailing ls could not score VALID. Per the recorded decision (option 2), such a denial is now set aside as a warning, like the plugin-data and own tool-results denials. The denied command is split at ;, &&, || and newlines; assignment-only and cd commands, and trailing ls/echo/cat (piped only into head or tail), are dropped. Exactly one command must remain, naming a path under the plugin directory, and a later undenied Bash call must equal it word for word (quotes removed, same-command variables resolved). A denial never recovered that way still fails. Closes #12256 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
claude-security-review reviewed Security review: PR #12373 (incremental, 089ade4..36d460a)I found no security issues in this round. What changed since the last review. This round fixes the two remaining owner-accepted threads. Both fixes only tighten the rule for setting a denial aside.
What I checked.
Round cap: not reached (0 of 3 rounds with findings). critical-findings: 0 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3d5b0dcb3b
ℹ️ 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".
…nd rule A recovered compound denial matched words with quotes removed, so an unquoted glob in the denied part could match a quoted literal in the later call, and a trailing ls/echo/cat that redirected into a file was dropped as a wrapper, excusing a denied write into the plugin. A plugin part left holding an unquoted glob, brace or tilde, or an unresolved $, no longer qualifies, and a word holding any of those is compared with its quoting. A trailing command is dropped only when its redirects name no file (2>&1, /dev/null), as bash_paths treats them. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
claude-review reviewed claude-review (code-review lane) on What I read: every hunk of the incremental diff in all three in-scope files: My two earlier findings are fixed, and their threads are settled with no lines changed since.
Tests: the new cases match the code paths they target:
Docs: Closing issue #12256: both "Done when" criteria are still met, as at the last review. The rule is recorded at Other checks:
Verification: this lane has no shell, so I ran neither the tests nor ruff. The PR's "134 tests OK" result comes from the owner's thread reply; it is the author's claim and is not verified here. |
…pound rule
A redirect glued to the word before it (echo '{}'>/p/state.json) was
not seen, and cd and assignment-only commands were dropped with no
redirect check, so a denied write into the plugin could be excused. A
dropped command now keeps the candidate whenever any word holds a < or
>, other than an fd duplication or close or a /dev/null target.
A $( inside double quotes, or a backtick, in any command of the denied
call, now refuses the candidate; $? and $VAR still pass.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Closes #12256
Summary
run-validity now sets aside a with-arm denied compound Bash call whose plugin part a later call in the same run ran alone and was allowed, and reports it as a warning (option 2, recorded on the issue). A denial whose plugin part never ran alone still counts.
Fix
run-validity.py: split the denied command at;,&&,||and newlines; drop assignment-only commands,cd, and trailingls/echo/cat(piped only intohead/tail). Exactly one command must remain, naming a path at or under the plugin directory, and a later non-denied call must equal it word for word after quote removal and same-command variable resolution. Commands holding&,(or)never qualify.reading-results.md#denialsrecords the rule as the fourth set-aside kind; evals changelog fragment (patch).Judgment call: the refinement asked for whitespace-normalized string equality; word matching with variables resolved is used instead, because dropping assignments only means something when the
$S/$PDthey set are substituted, and the issue's ownpathsexample is recovered only that way. It is no looser: a quoted"/a b"stays one word.Verification
python3 plugins/evals/skills/plugin-eval/scripts/test_run_validity.py: 131 tests OK. The recovered-compound test fails on main's script and passes with the fix; the never-recovered cases (no retry, other arguments, retry before the denial, retry denied, retry still wrapped, two commands left,echobefore the plugin part,ls | sh, nothing under the plugin, unresolved$(...),&and(...)) still FAIL.scripts/run-ruff.sh checkon both .py files: all checks passed.$(date)-built calls this rule does not cover).Related
🤖 Generated with Claude Code