-
Notifications
You must be signed in to change notification settings - Fork 1
55 lines (47 loc) · 1.57 KB
/
codeql.yml
File metadata and controls
55 lines (47 loc) · 1.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#######################################################################
# CodeQL — static security analysis #
# #
# Runs: #
# • On push to main (src changes only — skipped for docs/config) #
# • On PRs targeting main (src changes only) #
# • Weekly scheduled scan (Monday 6 AM UTC) — always runs to catch #
# new CVEs in unchanged code #
#######################################################################
name: CodeQL
on:
push:
branches: [main, "release/*"]
paths:
- 'src/**'
- 'pyproject.toml'
pull_request:
branches: [main]
paths:
- 'src/**'
- 'pyproject.toml'
schedule:
- cron: "0 6 * * 1" # Weekly — Monday 6 AM UTC
concurrency:
group: codeql-${{ github.ref }}
cancel-in-progress: true
jobs:
analyze:
name: "CodeQL analysis (Python)"
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
steps:
- uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: python
queries: security-extended,security-and-quality
- name: Autobuild
uses: github/codeql-action/autobuild@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:python"