Skip to content

Workflow lockfile follow-ups: transitive dependencies (702, 703, 713), staleness check, require-lockfile policy as a positive signal #545

Description

@Totara-thib

Is your feature request related to a problem? Please describe.

Follows #542 (reading the lockfile). Composite and JavaScript actions call other actions, and until now nothing in the repository said which ones. The lockfile records them: each dependency entry may carry a uses: list of the actions it calls, resolved to their own entries.

dependencies:
    'cli/gh-extension-precompile@v2.1.0':
        ref: 'v2.1.0'
        commit: 'sha1-9e2237c30f869ad3bcaed6a4be2cd43564dd421b'
        owner_id: 59704711
        repo_id: 421583656
        uses:
            - 'actions/attest-build-provenance@v1'
            - 'actions/setup-go@v5'
    'actions/attest-build-provenance@v1':
        ref: 'v1'
        commit: 'sha1-ef244123eb79f2f7a7e75d99086184180e6d0018'
        uses:
            - 'actions/attest-build-provenance@36fa7d009e22618ca7cd599486979b8150596c74'
            - 'actions/attest@67422f5511b7ff725f4dbd6fb9bd2cd925c65a8d'

Plumber evaluates the direct references only. An archived, known-vulnerable or untrusted action reached through a transitive entry runs with the same token and secrets as the direct one and is reported by nobody.

Describe the solution you'd like

Walk the transitive uses lists of the lockfile and evaluate the existing reference controls over them: actionsMustNotBeArchived (ISSUE-702), actionsMustNotBeKnownVulnerable (ISSUE-703) and githubActionMustComeFromAuthorizedSources (ISSUE-713). Findings name the path: actions/attest@67422f55 via cli/gh-extension-precompile@v2.1.0 in job release. The pin control does not apply, transitive entries are commits by construction.

Configuration in .plumber.yaml

controls:
  githubActionMustComeFromAuthorizedSources:
    # Transitive entries inherit the direct allowlist. Optional switch to
    # keep the first release quiet on repositories with deep trees:
    includeTransitive: true

Implementation Hints

  1. Data source: the lockfile dependency graph from Read GitHub workflow lockfiles (.github/workflows/actions.lock): locked refs count as pinned in ISSUE-701, lockfile consistency control, resolve the locked commit in 702/703 #542, flattened per onboarded workflow with the chain kept for the message.
  2. Logic: the same Rego rules, fed a second input set of (workflow, job, chain, uses) tuples, or the existing rules extended with an origin: transitive field on the IR uses entries.
  3. Severity: as the existing controls, one notch lower for transitive hits is a reasonable default (a transitive untrusted source is a medium rather than a high), to be decided with the bench.
  4. Default: on for 702 and 703, includeTransitive on for 713 with the allowlist shared.

Why It's Valuable

The transitive tree is the part of the supply chain the tj-actions incident actually travelled through (a compromised action pulled by other actions), and the lockfile is the first first-party source that enumerates it. Evaluating it puts Plumber ahead of every workflow scanner on the one dataset GitHub just made available.


Part 2, staleness check and the require-lockfile policy (merged from #546)

Is your feature request related to a problem? Please describe.

Two more facts about a lockfile matter and need the network to establish:

  • Staleness. gh actions-lock --verify checks that each locked commit still exists and is reachable from a branch of the source repository, and that a full-version tag (v4.2.1) still points at the locked commit. A locked commit that fell out of every branch is the signature of a force-pushed or rewritten upstream, exactly the case the lockfile exists to catch, and a repository that does not run --verify in CI never learns it.
  • The require-lockfile policy. Enterprise, organization and repository administrators can now require workflows to use lockfiles (preview). Like branch protection for ISSUE-501, it is a repository setting that only an admin can change and that materially raises the posture.

Describe the solution you'd like

  • A workflowLockfileMustBeCurrent control (medium): for each locked entry, confirm the commit exists and is reachable from a branch of the source repository (one compare call per entry, cached per owner/repo@commit), and that a full-version tag still points at it. Opt-in at first because of the API cost on large lockfiles, with the same token-free degradation Plumber applies to its other metadata checks.
  • If the GitHub REST or GraphQL API exposes the require-lockfile setting (to be verified, the preview may not expose it yet), read it for the scanned repository and surface it as a positive signal the way branch protection is read for ISSUE-501, including in the attack-path narrative.

Configuration in .plumber.yaml

controls:
  workflowLockfileMustBeCurrent:
    enabled: false   # opt-in until the API cost is measured

Implementation Hints

  1. Data source: the lockfile entries from Read GitHub workflow lockfiles (.github/workflows/actions.lock): locked refs count as pinned in ISSUE-701, lockfile consistency control, resolve the locked commit in 702/703 #542, the GitHub metadata client (github/github_metadata.go) for branch reachability and tag resolution, the repository settings client used by the branch-protection control for the policy, if exposed.
  2. Logic: reachability is compare base commit to each branch head or the commits?sha=<branch> walk the extension uses, tag check is git/ref/tags/<tag> against the locked commit.
  3. Severity: medium for a stale entry, informational for the policy.
  4. Default: opt-in for staleness, on for the policy read once it exists.

Why It's Valuable

Staleness is the only lockfile finding that detects an attack rather than a configuration gap, and the policy read makes the score reflect an admin decision GitHub now offers. Both complete the lockfile story after the first three issues.

Activity

  1. changed the title [-]Evaluate the transitive action dependencies the workflow lockfile enumerates (ISSUE-702, 703, 713)[/-] [+]Workflow lockfile follow-ups: transitive dependencies (702, 703, 713), staleness check, require-lockfile policy as a positive signal[/+] on Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions