-
Notifications
You must be signed in to change notification settings - Fork 1
batch 2 of 6: CI safe-patterns + supply-chain absorption #52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
3bb4655
74c6d47
09dc88f
7bc22f5
40a4333
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,166 @@ | ||||||||||
| # Zeta resume-claim diff reviewer-helper | ||||||||||
| # | ||||||||||
| # Runs on every PR that touches `docs/FACTORY-RESUME.md` or | ||||||||||
| # `docs/SHIPPED-VERIFICATION-CAPABILITIES.md` — the two files | ||||||||||
| # that form the factory's "job-interview honesty" surface per | ||||||||||
| # `memory/feedback_factory_resume_job_interview_honesty_only_direct_experience.md`. | ||||||||||
|
Comment on lines
+5
to
+6
|
||||||||||
| # that form the factory's "job-interview honesty" surface per | |
| # `memory/feedback_factory_resume_job_interview_honesty_only_direct_experience.md`. | |
| # that form the factory's "job-interview honesty" surface. |
Copilot
AI
Apr 22, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment uses a direct contributor name (“Aaron”), but repo guidance is to avoid name attribution in code/docs and use role references (e.g., “human maintainer”) except in explicitly exempt surfaces. Please rewrite this to use the role reference here.
| # judgment stays with the reviewer and with Aaron (honesty- | |
| # floor owner). | |
| # judgment stays with the reviewer and with the human | |
| # maintainer (honesty-floor owner). |
Copilot
AI
Apr 21, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On fork PRs, workflows triggered by pull_request commonly receive a read-only GITHUB_TOKEN, so gh pr comment can fail even if pull-requests: write is declared. To avoid noisy red runs, consider gating the comment step/job to same-repo PRs (or handling the failure explicitly), or document the required repo setting if write tokens for fork PRs are enabled intentionally.
Copilot
AI
Apr 21, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
grep -E doesn’t support \s (whitespace) or \b (word boundary), so this claim-line filter won’t match what it intends on ubuntu-22.04 (GNU grep treats these as literal characters). Use POSIX character classes like [[:space:]] and a word-boundary alternative (or switch to grep -P / perl) so the detection is actually effective under set -euo pipefail.
| | grep -E '^[+-]\s*(- \*\*|\| |#{2,4} |.*\b(ships?|shipped|verified|proven|complete[ds]?|honest|already absorbed|implement(ed|s)?|in[- ]repo evidence)\b)' \ | |
| | grep -E '^[+-][[:space:]]*(- \*\*|\| |#{2,4} |.*(^|[^[:alnum:]_])(ships?|shipped|verified|proven|complete[ds]?|honest|already absorbed|implement(ed|s)?|in[- ]repo evidence)([^[:alnum:]_]|$))' \ |
Copilot
AI
Apr 22, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gh pr comment will fail on fork PRs when the workflow is triggered via pull_request, because GITHUB_TOKEN is read-only for forks and cannot write PR comments. Since this step runs under set -euo pipefail, the whole workflow will go red for forked contributions. Make comment posting conditional on same-repo PRs, or switch to a hardened pull_request_target design (while ensuring you never execute PR-provided code) so the workflow behaves reliably.
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,89 @@ | ||||||||||
| # OpenSSF Scorecard — weekly project-health audit. | ||||||||||
| # | ||||||||||
| # Scorecard runs ~20 heuristic checks that score the repo on | ||||||||||
| # security-relevant posture: branch protection, signed releases, | ||||||||||
| # dangerous workflows, pinned dependencies, CII best practices, | ||||||||||
| # dependency-update tools, SAST coverage, token permissions, | ||||||||||
| # maintained-ness, and so on. Results upload to GitHub | ||||||||||
| # Security -> Code scanning as SARIF. | ||||||||||
| # | ||||||||||
| # Lane: factory. Orthogonal to the CVE scanners (Dependabot + | ||||||||||
| # `dotnet list --vulnerable`) - Scorecard audits *configuration*, | ||||||||||
| # not advisories. See `docs/research/vuln-and-dep-scanner- | ||||||||||
| # landscape-2026-04-22.md` adopt-now item #3 for the rationale. | ||||||||||
|
Comment on lines
+12
to
+13
|
||||||||||
| # not advisories. See `docs/research/vuln-and-dep-scanner- | |
| # landscape-2026-04-22.md` adopt-now item #3 for the rationale. | |
| # not advisories. See `docs/research/vuln-and-dep-scanner-landscape-2026-04-22.md` | |
| # adopt-now item #3 for the rationale. |
Copilot
AI
Apr 22, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This header comment includes an individual’s email address (ss...@google.com). Beyond name-attribution guidance, embedding personal identifiers in workflow comments tends to age badly and can be unnecessary PII in-repo. Consider replacing it with an organization/role reference (e.g., “OpenSSF maintainer”) and/or a link to the tagged release/verification evidence instead of a specific email.
| # 2025-09-30 by sschrock@google.com (OpenSSF maintainer), | |
| # 2025-09-30 by an OpenSSF maintainer, |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -340,3 +340,33 @@ rules: | |||||
| # "file lacks any of these headings"; a bespoke diff-level lint | ||||||
| # (which round-30 spec calls the "safety-clause-diff lint") is | ||||||
| # the stronger signal. Tracked in docs/DEBT.md; target round-31. | ||||||
|
|
||||||
| # ──────────────────────────────────────────────────────────────── | ||||||
| # Rule 17 — GitHub Actions workflow-injection: inline untrusted | ||||||
| # context on a `run:` line. The primary workflow-injection vector | ||||||
| # per https://github.blog/security/vulnerability-research/how-to- | ||||||
| # catch-github-actions-workflow-injections-before-attackers-do/. | ||||||
| # Matches single-line `run: ... ${{ github.<unsafe-path> }} ...` | ||||||
| # forms for the attacker-controlled contexts enumerated in | ||||||
| # docs/security/GITHUB-ACTIONS-SAFE-PATTERNS.md. Multi-line `run: | ||||||
| # |` blocks are covered by actionlint's YAML-aware parser. | ||||||
| # Fix: bind the value to an `env:` entry on the step and read it | ||||||
| # as `"$VAR"` in the shell. See the safe-patterns doc. | ||||||
| # ──────────────────────────────────────────────────────────────── | ||||||
| - id: gha-untrusted-in-run-line | ||||||
| patterns: | ||||||
| - pattern-regex: '(?m)^\s*-?\s*run:.*\$\{\{\s*github\.(head_ref|event\.(issue\.(title|body)|pull_request\.(title|body|head_ref|head\.ref|head\.label)|comment\.body|review\.body|head_commit\.message|commits))' | ||||||
|
||||||
| - pattern-regex: '(?m)^\s*-?\s*run:.*\$\{\{\s*github\.(head_ref|event\.(issue\.(title|body)|pull_request\.(title|body|head_ref|head\.ref|head\.label)|comment\.body|review\.body|head_commit\.message|commits))' | |
| - pattern-regex: '(?m)^\s*-?\s*run:.*\$\{\{\s*github\.((?:head_ref\b)|(?:event\.(?:issue\.(?:title|body)\b|pull_request\.(?:title|body|head_ref|head\.ref|head\.label)\b|comment\.body\b|review\.body\b|head_commit\.message\b|commits\[[^\]]+\]\.message\b)))' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The referenced script path looks incorrect: the repo path is
tools/setup/common/python-tools.sh, but this comment refers tocommon/python-tools.shwithout thetools/setup/prefix. Please fix the path so readers can find the script and pointer-integrity audits don’t flag it.