[llvm] [Github] Add CodeQL Action to check Github Actions Workflows (PR #158394)

Aiden Grossman via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 12 18:16:21 PDT 2025


https://github.com/boomanaiden154 created https://github.com/llvm/llvm-project/pull/158394

This should point out obvious security issues with our Github Actions workflows.

>From a91a861fe95bfae453c04b710feb4bdf40122bc0 Mon Sep 17 00:00:00 2001
From: Aiden Grossman <aidengrossman at google.com>
Date: Sat, 13 Sep 2025 01:15:26 +0000
Subject: [PATCH] [Github] Add CodeQL Action to check Github Actions Workflows

This should point out obvious security issues with our Github Actions
workflows.
---
 .github/workflows/gha-codeql.yml | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 .github/workflows/gha-codeql.yml

diff --git a/.github/workflows/gha-codeql.yml b/.github/workflows/gha-codeql.yml
new file mode 100644
index 0000000000000..87f1a5787b7a6
--- /dev/null
+++ b/.github/workflows/gha-codeql.yml
@@ -0,0 +1,30 @@
+name: Github Actions CodeQL
+
+permissions:
+  contents: read
+
+on:
+  pull_request:
+    branches:
+      - main
+
+concurrency:
+  group: ${{ github.workflow }}
+  cancel-in-progress: true
+
+jobs:
+  codeql:
+    name: 'Github Actions CodeQL'
+    runs-on: ubuntu-24.04
+    permissions:
+      security-events: write
+    steps:
+      - name: Checkout LLVM
+        uses: actions/checkout at 08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
+      - name: Initialize CodeQL
+        uses: github/codeql-action/init at 192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3
+        with:
+          languages: actions
+          queries: security-extended
+      - name: Perform CodeQL Analysis
+        uses: github/codeql-action/analyze at 192325c86100d080feab897ff886c34abd4c83a3 # v3.30.3



More information about the llvm-commits mailing list