From cb790fbebc1acdb9f532e7730b6f3afdba5f2224 Mon Sep 17 00:00:00 2001 From: mdheller <21163552+mdheller@users.noreply.github.com> Date: Sat, 4 Jul 2026 21:18:43 -0400 Subject: [PATCH] =?UTF-8?q?chore(ci):=20harden=20supply=20chain=20?= =?UTF-8?q?=E2=80=94=20pin=20actions=20to=20SHA=20+=20least-privilege=20pe?= =?UTF-8?q?rmissions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pin GitHub Actions to full commit SHA (floating tags are a supply-chain injection vector), add least-privilege permissions, and add dependabot to maintain the pins. --- .github/dependabot.yml | 6 ++++++ .github/workflows/validate.yml | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..5ace460 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index a02b80a..eb0ba35 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -6,15 +6,17 @@ on: branches: - main +permissions: + contents: read + jobs: validate: runs-on: ubuntu-latest steps: - name: Check out repository - uses: actions/checkout@v4 - + uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5 with: python-version: '3.12'