Skip to content

fix(security): isolate bundle checkouts and verify Git history - #160

Merged
rldyourmnd merged 1 commit into
mainfrom
fix/security-source-and-history-isolation
Oct 6, 2026
Merged

rldyourmnd merged 1 commit into
mainfrom
fix/security-source-and-history-isolation

Conversation

@rldyourmnd

@rldyourmnd rldyourmnd commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Private security calls reuse a fixed implementation checkout; files left by an earlier invocation can prevent the exact workflow revision from checking out. Allocate a fresh directory per call and preserve the existing files. Materialize and verify the selected history before Gitleaks so missing partial-clone objects cannot yield an incomplete successful scan.

Type of change

  • Fix to an existing workflow
  • Hardening / security posture improvement

Threat-model note

Implementation identity remains bound to the called workflow SHA. History hydration uses the existing read-only job token in process environment only, scoped to GitHub HTTPS; it is not written to the caller repository or passed on command arguments. Missing history fails before scanning. Selected ref-history/all-refs scope, scanner behavior, redacted evidence and runner routing are preserved.

Permissions diff

No permission changes: free bundle retains contents: read; paid bundle retains actions: read, contents: read and security-events: write; top-level permissions remain empty.

Validation

Actual YAML-step fixtures execute both variants twice with stale files, require distinct exact checkouts, preserve the stale sentinel and reject the old shared-directory control. Real partial-clone fixtures hydrate missing blobs and reject an unavailable promisor origin without persisting authorization. These focused checks, actionlint and pinned online zizmor 1.26.1 pass on macOS. All core validators pass against the exact published commit 9eb11c2 on the Ubuntu workstation. Touched-path validation is running separately; full scheduled link/calendar checks are advisory. macOS full validation encounters pre-existing fixture dependence on system tools.

Checklist

  • Full immutable action pins and least-privilege job permissions preserved.
  • Read-only checkout keeps persist-credentials: false.
  • Context values remain passed through env.
  • Catalog risks, caller examples and changelog updated; docs regenerated.
  • Signed and signed-off Conventional Commit.

Tier impact

  • Private free tier
  • Private paid tier

@github-actions github-actions Bot added ci and removed ci labels Oct 6, 2026
@rldyourmnd
rldyourmnd marked this pull request as ready for review October 6, 2026 19:57
@rldyourmnd
rldyourmnd merged commit 7bb306a into main Oct 6, 2026
30 checks passed
@rldyourmnd
rldyourmnd deleted the fix/security-source-and-history-isolation branch October 6, 2026 19:57
@github-actions github-actions Bot added ci and removed ci labels Oct 6, 2026
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.

1 participant