[ci] Add fuzzing workflow

Patch adds a fuzzing workflow to GH Actions. Workflow will guarantee
that building fuzzing tests is healthy.
This commit is contained in:
Sergey Bronnikov 2023-05-31 22:21:12 +03:00 committed by akallabeth
parent 979610b1fd
commit 2a1a411eaf
1 changed files with 42 additions and 0 deletions

42
.github/workflows/fuzzing.yml vendored Normal file
View File

@ -0,0 +1,42 @@
name: Fuzzing testing
on:
push:
branches:
- 'master'
pull_request:
types: [opened, reopened, synchronize, labeled]
jobs:
fuzzing:
if: github.repository == 'FreeRDP/FreeRDP'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sanitizer: [address]
steps:
- name: Build fuzzers (${{ matrix.sanitizer }})
id: build
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
with:
oss-fuzz-project-name: 'freerdp'
dry-run: false
sanitizer: ${{ matrix.sanitizer }}
- name: Run fuzzers (${{ matrix.sanitizer }})
uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master
with:
oss-fuzz-project-name: 'freerdp'
fuzz-seconds: 600
dry-run: false
sanitizer: ${{ matrix.sanitizer }}
- name: Upload crash
uses: actions/upload-artifact@v3
if: failure() && steps.build.outcome == 'success'
with:
name: ${{ matrix.sanitizer }}-artifacts
retention-days: 21
path: ./out/artifacts