You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(ci): the Kubescape guard accepts a scan handed to another interpreter #4164
Four ways of handing a scan to another interpreter pass scripts/validate-kubescape-frameworks on main (35031dbb), and they also pass the parser-backed prototype the Spike chose. In each case bash runs an nsa-only scan beside the real ksail workload scan --framework nsa,mitre --compliance-threshold 95 line.
#
Shape
1
bash <<'EOF' whose body is ksail workload scan --framework nsa
2
bash <<< 'ksail workload scan --framework nsa'
3
trap 'ksail workload scan --framework nsa' EXIT
4
xargs ksail <<< 'workload scan --framework nsa'
Each result was checked against bash with a stand-in ksail that records its arguments.
Audience and problem
Same gate as #3338: a reduced scan can overwrite the uploaded SARIF while the full invocation satisfies the guard. Neither the current reader nor the parser looks inside text that another command later runs as shell.
Direction
Once the guard is parser-backed (#3579), run the same analysis on text handed to bash/sh through a heredoc or here-string, on trap strings, and on input fed to xargs ksail. Where that text cannot be read, refuse it if it names a scan word, the rule bash -c strings already follow.
Acceptance criteria
All four shapes are refused, each by a test that fails today.
Controls stay accepted: bash <<'EOF' running echo hello, trap 'rm -f out.txt' EXIT, and the real workflows.
Delivered by merged PR #4431, reviewed source commit 06d951f.
All four original interpreter-delegation shapes are refused by regressions and Bash recording witnesses. Ordinary interpreter heredocs, cleanup traps, and the real workflows remain accepted. The same bounded analysis supplies both admission paths, including delegated code and input whose behavior can be proved.
Acceptance was checked against the original issue body. The original historical test file is unchanged. All 266 test/subtest assertions passed with race detection, including 28 Bash recording witnesses; source CI and protected merge-queue CI passed. Closing as completed.
Activity
chore: agent-claim #4164 nonce=97c2697f5620a5ff992287ccd6e6a542
chore: agent-claim #4164 nonce=039253a1bb509ee723c573bab0dbe025
devantler commentedon Oct 3, 2026
Delivered by merged PR #4431, reviewed source commit 06d951f.
All four original interpreter-delegation shapes are refused by regressions and Bash recording witnesses. Ordinary interpreter heredocs, cleanup traps, and the real workflows remain accepted. The same bounded analysis supplies both admission paths, including delegated code and input whose behavior can be proved.
Acceptance was checked against the original issue body. The original historical test file is unchanged. All 266 test/subtest assertions passed with race detection, including 28 Bash recording witnesses; source CI and protected merge-queue CI passed. Closing as completed.