Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/security_scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Security Scanning

on:
push:
branches:
- main
pull_request:

jobs:
security_scan:
name: Run security scans
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[dev]

- name: Run pip-audit
uses: pypa/[email protected]
with:
inputs: requirements.txt
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to do all the requirements-*.txt to check the mpi/optional/nvidia ones too


- name: Run Bandit
uses: PyCQA/bandit-action@v1
with:
path: '.'
level: 'high'
confidence: 'high'
exit_zero: false

- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
with:
scan-type: 'fs'
scan-ref: '.'
format: 'table'
exit-code: '1'
ignore-unfixed: true
severity: 'CRITICAL,HIGH'


Loading