diff --git a/.github/workflows/semgrep.yml b/.github/workflows/semgrep.yml new file mode 100644 index 00000000..980e919b --- /dev/null +++ b/.github/workflows/semgrep.yml @@ -0,0 +1,30 @@ +name: Semgrep + +on: + push: + branches: + - main + pull_request: + +permissions: + contents: read + actions: read + security-events: write + +jobs: + scan: + runs-on: ubuntu-latest + container: + image: semgrep/semgrep + if: (github.actor != 'dependabot[bot]') + steps: + - uses: actions/checkout@v4 + - run: semgrep scan --config=auto --sarif --output=semgrep.sarif + env: + SEMGREP_RULES: auto + - name: Upload SARIF file + uses: github/codeql-action/upload-sarif@v4 + with: + sarif_file: semgrep.sarif + category: semgrep + if: always()