Repository navigation
fix(tier3): preserve scoped NUL-delimited temporary-file cleanup - #790
Conversation
Follow up on the reviewed Tier 3 cleanup policy with focused host and verifier regressions. Signed-off-by: YMuskrat <101849520+YMuskrat@users.noreply.github.com>
rng1995
left a comment
There was a problem hiding this comment.
Thank you for the contribution! Reviewed the narrow NUL-delimited cleanup grammar, root containment, rejection cases and host/verifier parity. Destructive-command, scoped-cleanup and cache suites passed (3,734 tests). No blocking findings; the existing characters-versus-bytes documentation nit remains nonblocking.
rng1995
left a comment
There was a problem hiding this comment.
Thanks @YMuskrat for this contribution! I reviewed 78ebecc366. I reproduced the problem on main, and ran the new and related tests on this head (all pass). I left 3 inline comments (1 P2, 2 P3); please address them before this is merged.
Refresh from upstream main, compare retained quotes with actual POSIX shell words, and cover the reported producer bypass in both security checkers. Clarify the restored scoring behavior, literal filters, and character bound. Co-authored-by: Codex <codex@openai.com> Signed-off-by: YMuskrat <101849520+YMuskrat@users.noreply.github.com>
|
Fixed and pushed in 2fdf147. The quoted-word bypass is covered by the POSIX word check and host/verifier regressions. Focused local tests pass; full-suite failures also reproduce on unchanged main. |
Summary
Preserve Security 1.0 for a narrow temporary-file cleanup pipeline:
find /tmp/cache -type f -print0 | xargs -0 -r rm -f. Recognize only one literal temporary-root producer, non-following file selection, NUL output/input and force-only removal without written targets. Optional quoted name filters and the documented null/no-run-if-empty spellings are supported.Unknown producers, whitespace-delimited output, unquoted globs, link-following options, traversal, alternate xargs inputs, replacement targets, recursive removal, extra commands and earlier symlink evidence keep the destructive finding. This is the existing command-text policy, not a runtime filesystem-containment guarantee.
Implements the optional producer-aware direction on #231 with a deliberately narrower NUL-safe first version; the plain whitespace examples remain conservative.
Verification
make lint, wheel/source build and Fern validation passedmake test: 2,621 passed, 3 skipped, 4 failed before the failure limit. Those four cases also fail on unchanged upstreamaffe1acwith the same locked dependencies and isolated temporary directory. Full-suite success is not claimed.Python 3.12; test commands are classifier strings, not executed deletions. The exemption is bounded to 4 KiB and 128 words and retains conservative handling when parsing is uncertain.
Release Impact