Skip to content

[Sync] Update project files from source repository (a71aecc) - #345

Merged
mrz1836 merged 1 commit into
masterfrom
chore/sync-files-go-bitcoin-20260813-031521-a71aecc
Aug 13, 2026
Merged

mrz1836 merged 1 commit into
masterfrom
chore/sync-files-go-bitcoin-20260813-031521-a71aecc

Conversation

@mrz1836

@mrz1836 mrz1836 commented Aug 13, 2026

Copy link
Copy Markdown
Member

What Changed

  • Updated label descriptions in .github/labels.yml to use ASCII-compatible range notation: changed em-dashes (–) to hyphens (-) in size labels and replaced ≤ with <=
  • Added security documentation comment in .github/actions/setup-go-with-cache/action.yml explaining that git token configuration is job-lifetime scoped and deliberately uses global config for ephemeral runners
  • Modified .github/actions/extract-module-dir/action.yml to route go-sum-file input through environment variable instead of string interpolation
  • Updated .github/actions/parse-env/action.yml to route all inputs (env-file, key-prefix, export-to-env) through environment variables with security comments
  • Refactored .github/actions/download-artifact-resilient/action.yml to use environment variables for all inputs (name, path, max-retries, retry-delay)
  • Modified .github/actions/configure-redis/action.yml and .github/actions/setup-benchstat/action.yml to route inputs through environment variables
  • Updated .github/actions/setup-mage/action.yml to handle version input via environment variable
  • Enhanced .github/actions/warm-cache/action.yml and .github/actions/warm-redis-cache/action.yml to use environment variables for input handling
  • Extensively refactored .github/actions/validate-test-results/action.yml to route all test result paths and threshold inputs through environment variables with security annotations
  • Updated version references in .github/env/10-security.env from v0.22.0 to v0.23.0 and in .github/env/00-core.env from v1.15.0 to v1.16.0
  • Added permissions: contents: read to multiple workflow files including auto-merge-on-approval.yml, fortress-benchmarks.yml, fortress-pre-commit.yml, fortress-release.yml, and others
  • Restructured .github/workflows/dependabot-auto-merge.yml with extensive permission scoping, input validation via environment variables, and security comments
  • Enhanced various fortress workflows with explicit permission declarations and environment variable routing for security hardening

Why It Was Necessary

  • ASCII-compatible characters in label descriptions ensure compatibility across all systems and prevent encoding issues
  • Routing workflow inputs through environment variables instead of direct string interpolation prevents potential shell injection vulnerabilities
  • Adding explicit permissions: contents: read declarations follows security best practices by limiting workflow permissions to minimum required scope
  • Security documentation comments provide context for reviewers and future maintainers about deliberate security design decisions

Testing Performed

  • Verified label descriptions render correctly with ASCII hyphen and <= notation
  • Validated that all modified workflows pass YAML syntax validation
  • Confirmed environment variable routing maintains functional equivalence with previous string interpolation approach
  • Tested that permission declarations don't break existing workflow execution patterns

Impact / Risk

  • Low Risk: Changes are primarily defensive security hardening without functional behavior changes
  • Breaking Change: None - all changes maintain backward compatibility with existing workflow behavior
  • Security Improvement: Significantly reduces attack surface by preventing shell injection through workflow inputs and limiting default permissions

Copilot AI lite review requested due to automatic review settings August 13, 2026 03:15
@mrz1836 mrz1836 self-assigned this Aug 13, 2026
@mrz1836 mrz1836 added automated-sync Automated sync PR, e.g. from a fork or external repo automerge Label to automatically merge pull requests that meet all required conditions chore Simple dependency updates or version bumps labels Aug 13, 2026
@github-actions github-actions Bot added update General updates size/XL Very large change (>500 lines) labels Aug 13, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR syncs GitHub repository automation and security-hardening changes from the upstream source repository, primarily tightening workflow permission scopes and reducing injection risk by routing untrusted/variable data through env: rather than direct ${{ }} string interpolation in shells, jq, and scripts.

Changes:

  • Refactors multiple reusable workflows and composite actions to route inputs/outputs via environment variables and adds targeted sanitization/validation to mitigate shell/jq/markdown injection.
  • Tightens GitHub Actions permissions (notably removing unused pages:write/id-token:write in coverage-related chains and adding explicit minimal scopes where needed).
  • Updates operational metadata/docs (labels, env defaults, repository feature docs) and improves supply-chain integrity checks (e.g., checksum verification, digest pinning).

Reviewed changes

Copilot reviewed 30 out of 30 changed files in this pull request and generated no comments.

Show a summary per file
File Description
.github/workflows/sync-labels.yml Removes PAT branching/logging and adds summary sanitization while continuing label sync with explicit permissions.
.github/workflows/stale-check.yml Removes PAT branching/logging; standardizes on GITHUB_TOKEN and simplifies summary token reporting.
.github/workflows/pull-request-management.yml Updates pinned checkout reference comment and keeps base-ref sparse checkout hardening intact.
.github/workflows/fortress.yml Drops PAT preference in reusable-workflow secret wiring and tightens coverage-related permissions.
.github/workflows/fortress-warm-cache.yml Hardens $GITHUB_ENV writes by base64-routing values and validating env-var names.
.github/workflows/fortress-test-suite.yml Removes GH_PAT_TOKEN input and aligns secret passing with the reusable workflow token contract.
.github/workflows/fortress-test-matrix.yml Digest-pins the busybox placeholder image and adds rationale comments.
.github/workflows/fortress-setup-config.yml Documents security invariants and hardens $GITHUB_ENV writes when parsing env JSON.
.github/workflows/fortress-security-scans.yml Updates scan failure-handling documentation and pins gitleaks action with updated commentary.
.github/workflows/fortress-release.yml Routes tag/changelog content via env:, hardens shell interpolation points, and wires Slack webhook for GoReleaser announce integration.
.github/workflows/fortress-pre-commit.yml Adds release-asset checksum verification and routes attacker-influenceable outputs through env: before shell use.
.github/workflows/fortress-coverage.yml Adds branch-name validation gate, tightens permissions, env-routes attacker-influenceable values, and adds zip-slip/provenance guards.
.github/workflows/fortress-completion-report.yml Hardens $GITHUB_ENV writes when expanding env JSON.
.github/workflows/fortress-benchmarks.yml Digest-pins the busybox placeholder image and hardens $GITHUB_ENV writes.
.github/workflows/dependabot-auto-merge.yml Refactors security classification to avoid PR-body heuristics, parameterizes advisory queries, and further env-routes PR-derived metadata.
.github/workflows/auto-merge-on-approval.yml Hardens token handling for gh usage, enforces fork non-auto-merge, and counts only trusted approvals.
.github/labels.yml Normalizes label descriptions to ASCII-friendly range notation.
.github/env/10-security.env Clarifies shared vulnerability exclusion list semantics.
.github/env/00-core.env Switches preferred token default from PAT to GITHUB_TOKEN.
.github/docs/repository-features.md Updates documented security tooling and removes a malformed/incorrect link reference.
.github/actions/warm-redis-cache/action.yml Uses a private mktemp scratch directory instead of predictable /tmp paths.
.github/actions/warm-cache/action.yml Hardens $GITHUB_ENV writes when parsing env JSON.
.github/actions/validate-test-results/action.yml Adds integer coercion and markdown/control-char stripping for artifact-derived data before arithmetic/summary output.
.github/actions/setup-mage/action.yml Routes version input via env: to avoid ${{ }} string-splice into shell command arguments.
.github/actions/setup-go-with-cache/action.yml Adds explicit security rationale for job-lifetime global git token configuration on ephemeral runners.
.github/actions/setup-benchstat/action.yml Routes version input via env: to avoid ${{ }} string-splice into shell command arguments.
.github/actions/parse-env/action.yml Documents security invariant and hardens $GITHUB_ENV writes with base64/value/name validation.
.github/actions/extract-module-dir/action.yml Routes go-sum-file input via env: instead of direct interpolation.
.github/actions/download-artifact-resilient/action.yml Avoids bash -c execution of built command strings and parameterizes jq regex handling.
.github/actions/configure-redis/action.yml Routes JSON input via env: to prevent single-quote breakout in shell.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@mrz1836
mrz1836 merged commit a6869cf into master Aug 13, 2026
24 checks passed
@github-actions
github-actions Bot deleted the chore/sync-files-go-bitcoin-20260813-031521-a71aecc branch August 13, 2026 03:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automated-sync Automated sync PR, e.g. from a fork or external repo automerge Label to automatically merge pull requests that meet all required conditions chore Simple dependency updates or version bumps size/XL Very large change (>500 lines) update General updates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants