Skip to content
Merged
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
121 changes: 121 additions & 0 deletions .github/workflows/semgrep.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
name: Semgrep SAST Scan

on:
push:
branches:
- master
pull_request:
branches: [ "master" ]
schedule:
# Run a full scan every Monday at midnight
- cron: '0 0 * * 1'
workflow_dispatch:

jobs:
semgrep-android:
name: Semgrep Scan (Android)
runs-on: ubuntu-latest

permissions:
actions: read
contents: read
security-events: write

container:
image: semgrep/semgrep:1.171.0@sha256:bdf7013b2c3634a487671158da77c554f531742326b543a9464d2adf6c433ac8

steps:
- name: Checkout Code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false

- name: Run Semgrep Scan
run: >-
semgrep scan
--config p/security-audit
--config p/secrets
--config p/owasp-top-ten
--config p/kotlin
BlinkID/android
--sarif
--output=semgrep.sarif

- name: Upload SARIF Results to GitHub Security Tab
uses: github/codeql-action/upload-sarif@f205ea1c3313d32999d8d6a48b4f6530d4437b38 # v4.37.4
if: always()
with:
sarif_file: semgrep.sarif
category: semgrep-android

semgrep-ios:
name: Semgrep Scan (iOS)
runs-on: ubuntu-latest

permissions:
actions: read
contents: read
security-events: write

container:
image: semgrep/semgrep:1.171.0@sha256:bdf7013b2c3634a487671158da77c554f531742326b543a9464d2adf6c433ac8

steps:
- name: Checkout Code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false

- name: Run Semgrep Scan
run: >-
semgrep scan
--config p/security-audit
--config p/secrets
--config p/owasp-top-ten
--config p/swift
BlinkID/ios
--sarif
--output=semgrep.sarif

- name: Upload SARIF Results to GitHub Security Tab
uses: github/codeql-action/upload-sarif@f205ea1c3313d32999d8d6a48b4f6530d4437b38 # v4.37.4
if: always()
with:
sarif_file: semgrep.sarif
category: semgrep-ios

semgrep-dart:
name: Semgrep Scan (Dart)
runs-on: ubuntu-latest

permissions:
actions: read
contents: read
security-events: write

container:
image: semgrep/semgrep:1.171.0@sha256:bdf7013b2c3634a487671158da77c554f531742326b543a9464d2adf6c433ac8

steps:
- name: Checkout Code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false

- name: Run Semgrep Scan
run: >-
semgrep scan
--config p/security-audit
--config p/secrets
--config p/owasp-top-ten
BlinkID/lib
sample_files
--sarif
--output=semgrep.sarif

- name: Upload SARIF Results to GitHub Security Tab
uses: github/codeql-action/upload-sarif@f205ea1c3313d32999d8d6a48b4f6530d4437b38 # v4.37.4
if: always()
with:
sarif_file: semgrep.sarif
category: semgrep-dart