Skip to content

Security

Security #67

Workflow file for this run

name: Security
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
# Run weekly on Monday at 06:00 UTC to catch new CVEs in dependencies
- cron: '0 6 * * 1'
permissions:
contents: read
security-events: write
jobs:
dependency-audit:
name: Dependency Audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install dependencies (non-editable)
run: pip install ".[dev]"
- name: Install pip-audit
run: pip install pip-audit
- name: Audit dependencies for known vulnerabilities
run: |
pip freeze | grep -iv intentkeeper > /tmp/deps.txt
pip-audit --strict --desc -r /tmp/deps.txt
codeql:
name: CodeQL Analysis
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: python
- name: Run CodeQL Analysis
uses: github/codeql-action/analyze@v3
secrets-scan:
name: Secrets Scan
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Scan for hardcoded secrets
uses: gitleaks/gitleaks-action@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}