mirror of
https://github.com/Vateron-Media/XC_VM.git
synced 2026-10-07 20:02:40 +02:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 6 to 7. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v6...v7) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
57 lines
1.4 KiB
YAML
57 lines
1.4 KiB
YAML
name: Security Scan
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- 'src/**/*.php'
|
|
- 'src/**/*.sh'
|
|
- '.github/workflows/security-scan.yml'
|
|
pull_request:
|
|
paths:
|
|
- 'src/**/*.php'
|
|
- 'src/**/*.sh'
|
|
- '.github/workflows/security-scan.yml'
|
|
workflow_dispatch:
|
|
schedule:
|
|
- cron: '0 6 * * 1'
|
|
- cron: '0 6 * * 4'
|
|
|
|
permissions:
|
|
contents: read
|
|
security-events: write
|
|
|
|
jobs:
|
|
semgrep:
|
|
name: Semgrep Security Scan
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: semgrep/semgrep
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v7
|
|
|
|
- name: Run Semgrep
|
|
# Blocking on push to main / schedule; informative-only on pull requests
|
|
# (PR findings still surface in the Security tab via the SARIF upload).
|
|
continue-on-error: ${{ github.event_name == 'pull_request' }}
|
|
run: |
|
|
semgrep scan \
|
|
--config "p/php" \
|
|
--config "p/security-audit" \
|
|
--config "p/command-injection" \
|
|
--config "p/sql-injection" \
|
|
--config "p/xss" \
|
|
--sarif \
|
|
--output semgrep-results.sarif \
|
|
--error \
|
|
--severity ERROR \
|
|
src/
|
|
|
|
- name: Upload SARIF
|
|
if: always()
|
|
uses: github/codeql-action/upload-sarif@v4
|
|
with:
|
|
sarif_file: semgrep-results.sarif
|
|
category: semgrep
|