Skip to content

security: Vault Sentinel reads mainframe credential shapes (Part of #8625) - #8631

Merged
squid-shepherd[bot] merged 4 commits into
mainfrom
churn/8625-20261118T1929Z
Nov 18, 2026
Merged

squid-shepherd[bot] merged 4 commits into
mainfrom
churn/8625-20261118T1929Z

Conversation

@squid-protocol

Copy link
Copy Markdown
Owner

Part of #8625 (security epic #8427). Slice 1: Vault Sentinel reads mainframe credential shapes.

What

SecurityLens's hardcoded_secrets wants a quoted value of 16+ characters; a JCL PASSWORD= is at most 8 characters and unquoted, so those leaks passed. New leaf module gitgalaxy/security/mainframe_secrets.py (mainframe_secret_hits) is added to Vault Sentinel's content check beside EXTRA_SECRETS. It feeds Sentinel only, so engine scoring and golden masters do not move. Redaction is unchanged (one [REDACTED] line per hit, never the value).

Shapes, each with a planted case and a near-miss, run through the real Sentinel (nothing mocked) over extensionless members and .jcl / .rexx names:

  • JCL PASSWORD= on JOB (also the (old,new) form); PARM='... PASSWORD=x' on EXEC.
  • In-stream (DD * / DD DATA) FTP USER id pw and PASS pw lines.
  • Db2 CONNECT TO x USER u USING literal, in REXX or embedded SQL.
  • REXX pw = 'literal' and CLIST SET &PW = literal within 5 lines of a user ID.
  • Near-misses quiet: &PW symbolics, :PW host variables, //* / /* */ / COBOL * comments, empty or computed values, a literal with no user ID nearby, USER with no password, FTP-looking lines outside a data card, and a RACF ALTUSER ... PASSWORD(...) documentation member.

Manuals are named in the module docstring by title (z/OS MVS JCL Reference JOB/EXEC; Communications Server IP User's Guide and Commands FTP; Db2 for z/OS SQL Reference CONNECT; TSO/E REXX Reference and CLISTs). I could not open them from this environment, so page numbers are not cited and the syntax forms are from memory of those manuals: a reviewer should check them.

Class / Sibling gaps

Class: credential shapes mainframe estates leak that the engine's hardcoded_secrets signature cannot read (short or unquoted values, JCL/FTP/Db2-connect syntax). Handled here: JCL PASSWORD, EXEC PARM, FTP in-stream USER/PASS, Db2 CONNECT literal, REXX and CLIST literal beside a user ID. Sibling gaps: (1) a PARM= continued across several JCL lines is read per line only; (2) in-stream FTP using a .netrc-style machine/login/password card; (3) Db2 CONNECT split across lines in embedded SQL; (4) REXX/CLIST literals more than 5 lines from the user ID, or a user ID inside a PROC symbolic default; (5) the engine's own galaxyscope scan (SARIF, scoring) does not report these shapes: that would move golden masters and needs its own slice; (6) whether the aperture reads JCL/PROC/REXX/CLIST members for the engine scan, as the issue asks, is not checked here (Sentinel reads any text file).

Remaining slices

  1. Engine-side signature for the shapes (SecurityLens, golden re-bless), order: after this.
  2. Aperture check for JCL/PROC/REXX/CLIST members, own slice if one is not scanned.
  3. Multi-line PARM, .netrc card and multi-line CONNECT.

Gates

pytest the three vault_sentinel test files: 113 passed. pr_gates --fast: 9/9 pass (lint, audits, secrets, xray, gen-docs, derived, workflows, gauntlet, affected). churn selfcheck: 0 problems.

🤖 Generated with Claude Code

@squid-protocol squid-protocol added the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 18, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 18, 2026 20:19
@squid-shepherd

Copy link
Copy Markdown
Contributor

PR #8631 @ 5f4973a: 1 failed check(s)

== Small audits (failure) -- real
https://github.com/squid-protocol/gitgalaxy/actions/runs/44389598898/job/135103320217
repro: no local equivalent; read the check page
errors:
doc-refs: FAIL, 1 new finding(s). Fix the doc (or the code), or narrow the check in this script:
##[error]Process completed with exit code 1.
log tail:
{
echo "## ⚠️ This PR modifies a golden-crucible fixture"
echo ""
echo "Files changed ($(echo "$CHANGED" | wc -l) golden-master part(s)):"
echo '' echo "$CHANGED" | head -n 100 echo ''
echo ""
echo "These files should only ever change via `tests/tools/update_golden_master.py`,"
echo "and the PR description should explain why GitGalaxy's output was expected to"
echo "change. Reviewers: confirm the description covers this before approving."
echo "For the semantic diff: `python tests/tools/bless_scope.py --from-head tests/golden_master_audit`."
} >> "$GITHUB_STEP_SUMMARY"
shell: /usr/bin/bash -e {0}
env:
pythonLocation: /opt/hostedtoolcache/Python/3.12.16/x64
PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.12.16/x64/lib/pkgconfig
Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.16/x64
Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.16/x64
Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.12.16/x64
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.12.16/x64/lib
BASE_REF: main
##[endgroup]
No golden master fixture changes in this PR.
Post job cleanup.
[command]/usr/bin/git version
git version 2.56.1
Temporarily overriding HOME='/home/runner/work/_temp/957aaad3-12b7-4998-888b-02ffab2e0443' before making global git config changes
Adding repository directory to the temporary git global config as a safe directory
[command]/usr/bin/git config --global --add safe.directory /home/runner/work/gitgalaxy/gitgalaxy
Removing SSH command configuration
[command]/usr/bin/git config --local --name-only --get-regexp core.sshCommand
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core.sshCommand' && git config --local --unset-all 'core.sshCommand' || :"
Removing HTTP extra header
[command]/usr/bin/git config --local --name-only --get-regexp http.https://github.com/.extraheader
[command]/usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http.https://github.com/.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :"
Removing includeIf entries pointing to credentials config files
[command]/usr/bin/git config --local --name-only --get-regexp ^includeIf.gitdir:
[command]/usr/bin/git submodule foreach --recursive git config --local --show-origin --name-only --get-regexp remote.origin.url
Cleaning up orphan processes

@squid-shepherd squid-shepherd Bot added the shepherd:needs-fix Bot: a real failure on this head; see the digest comment. Guide: docs/ci.md label Nov 18, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🐦‍⬛ Muninn Security Scan

✅ No security issues found.

🐦‍⬛ Powered by Muninn · Skald Lab

@squid-protocol squid-protocol added shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md and removed shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md labels Nov 18, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd

Copy link
Copy Markdown
Contributor

CI shepherd: the head of this PR (667f237) is not the one a maintainer labelled shepherd:merge on (new commits, or never approved), so the label was removed and nothing merges unreviewed code. Re-add the label when the new head is ready (shepherd:reapprove marks this PR until then). Until then it is a draft and runs the cheap audits only; re-adding the label marks it ready, which starts the full set on that head.

@squid-shepherd squid-shepherd Bot removed the shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md label Nov 18, 2026
@squid-shepherd
squid-shepherd Bot marked this pull request as draft November 18, 2026 21:04
@squid-shepherd squid-shepherd Bot added shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md and removed shepherd:needs-fix Bot: a real failure on this head; see the digest comment. Guide: docs/ci.md labels Nov 18, 2026
@squid-protocol squid-protocol added shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md and removed shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md labels Nov 18, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 18, 2026 21:08
@squid-shepherd squid-shepherd Bot added the shepherd:retrying Bot: an infra/flake rerun is pending on this head. Guide: docs/ci.md label Nov 18, 2026
@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 18, 2026 21:08
@squid-shepherd squid-shepherd Bot removed shepherd:retrying Bot: an infra/flake rerun is pending on this head. Guide: docs/ci.md shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md labels Nov 18, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

CI shepherd: the head of this PR (83c2b10) is not the one a maintainer labelled shepherd:merge on (new commits, or never approved), so the label was removed and nothing merges unreviewed code. Re-add the label when the new head is ready (shepherd:reapprove marks this PR until then). Until then it is a draft and runs the cheap audits only; re-adding the label marks it ready, which starts the full set on that head.

@squid-shepherd
squid-shepherd Bot marked this pull request as draft November 18, 2026 22:06
auto-merge was automatically disabled November 18, 2026 22:06

Pull request was converted to draft

@squid-shepherd squid-shepherd Bot added the shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md label Nov 18, 2026
@squid-protocol squid-protocol added shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md and removed shepherd:reapprove Bot: new commits dropped shepherd:merge; re-add it to merge this head. Guide: docs/ci.md labels Nov 18, 2026
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd
squid-shepherd Bot marked this pull request as ready for review November 18, 2026 22:08
@squid-shepherd squid-shepherd Bot added the shepherd:retrying Bot: an infra/flake rerun is pending on this head. Guide: docs/ci.md label Nov 18, 2026
@squid-shepherd
squid-shepherd Bot enabled auto-merge (squash) November 18, 2026 22:09
@squid-shepherd

Copy link
Copy Markdown
Contributor

No description provided.

@squid-shepherd squid-shepherd Bot removed the shepherd:retrying Bot: an infra/flake rerun is pending on this head. Guide: docs/ci.md label Nov 18, 2026
@squid-shepherd
squid-shepherd Bot merged commit bc89733 into main Nov 18, 2026
111 of 143 checks passed
@squid-shepherd
squid-shepherd Bot deleted the churn/8625-20261118T1929Z branch November 18, 2026 23:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

shepherd:merge Maintainer: merge when green (auto-merge, squash). Guide: docs/ci.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant