Skip to content

Commit

Permalink
ci: turn on ClusterFuzzLite
Browse files Browse the repository at this point in the history
  • Loading branch information
evverx committed Dec 6, 2021
1 parent 1200e7d commit 6c55f0f
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .clusterfuzzlite/Dockerfile
@@ -0,0 +1,9 @@
FROM gcr.io/oss-fuzz-base/base-builder:v1
RUN apt-get update && \
apt-get install -y pkg-config make autoconf autopoint zlib1g-dev flex bison gawk
COPY . $SRC/elfutils
RUN git clone --depth 1 https://github.com/google/oss-fuzz && \
cp oss-fuzz/projects/elfutils/build.sh $SRC/ && \
cp oss-fuzz/projects/elfutils/fuzz-dwfl-core.c $SRC/ && \
cp oss-fuzz/projects/elfutils/fuzz-dwfl-core_seed_corpus.zip $SRC/
WORKDIR elfutils
1 change: 1 addition & 0 deletions .clusterfuzzlite/project.yaml
@@ -0,0 +1 @@
language: c
24 changes: 24 additions & 0 deletions .github/workflows/cflite_build.yml
@@ -0,0 +1,24 @@
name: ClusterFuzzLite continuous builds
on:
push:
branches: [main]

permissions: read-all

jobs:
Build:
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ matrix.sanitizer }}-${{ github.ref }}
cancel-in-progress: true
strategy:
fail-fast: false
matrix:
sanitizer: [address, undefined, memory]
steps:
- name: Build Fuzzers (${{ matrix.sanitizer }})
id: build
uses: google/clusterfuzzlite/actions/build_fuzzers@v1
with:
sanitizer: ${{ matrix.sanitizer }}
upload-build: true
31 changes: 31 additions & 0 deletions .github/workflows/cflite_pr.yml
@@ -0,0 +1,31 @@
name: ClusterFuzzLite PR fuzzing
on:
pull_request:
branches: [main]

permissions: read-all

jobs:
PR:
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ matrix.sanitizer }}-${{ github.ref }}
cancel-in-progress: true
strategy:
fail-fast: false
matrix:
sanitizer: [address, undefined, memory]
steps:
- name: Build Fuzzers (${{ matrix.sanitizer }})
id: build
uses: google/clusterfuzzlite/actions/build_fuzzers@v1
with:
sanitizer: ${{ matrix.sanitizer }}
- name: Run Fuzzers (${{ matrix.sanitizer }})
id: run
uses: google/clusterfuzzlite/actions/run_fuzzers@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
fuzz-seconds: 180
mode: 'code-change'
sanitizer: ${{ matrix.sanitizer }}

0 comments on commit 6c55f0f

Please sign in to comment.