Skip to content

CI: pin GitHub Actions by commit SHA #56

Open

Description

@phantoslayer21

.github/workflows/ci.yml references its three actions by version tag (actions/checkout@v4.2.2, actions/setup-python@v5.3.0, ilammy/msvc-dev-cmd@v1.13.0). A tag can be moved by whoever controls the action's repository; a commit SHA cannot.

The exposure is small (the workflow has contents: read, no secrets, and publishes nothing), but pinning by SHA is the usual hardening for a public repository that takes outside pull requests.

To do

  • Replace each tag with the 40-character commit SHA of that release, with the tag in a trailing comment (uses: actions/checkout@<sha> # v4.2.2).
  • Optionally add .github/dependabot.yml for the github-actions ecosystem so updates stay easy.
  • Optionally a line in the licence-and-line-endings job that fails when a workflow uses an action that is not pinned by SHA.

Activity

  1. added this to the 0.6.1 milestone on Nov 13, 2026
  2. added
    build
    area: build-ci
    on Nov 13, 2026
  3. modified the milestones: 0.6.5, 0.6.6 on Nov 14, 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

    area: build-cibuild

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions