-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from jmartins-ledger/clusterfuzzlite-support
Clusterfuzzlite support
- Loading branch information
Showing
9 changed files
with
127 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
FROM gcr.io/oss-fuzz-base/base-builder:v1 | ||
RUN apt-get update && apt-get install -y make libssl-dev libbsd-dev | ||
COPY . $SRC/app-stellar | ||
WORKDIR $SRC/app-stellar | ||
COPY .clusterfuzzlite/build.sh $SRC/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/bin/bash -eu | ||
|
||
# build fuzzers | ||
|
||
pushd fuzz | ||
./build.sh | ||
mv ./cmake-build-fuzz/fuzz_tx $OUT/app-stellar-fuzz-tx | ||
popd | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
language: c++ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: ClusterFuzzLite batch fuzzing | ||
on: | ||
schedule: | ||
- cron: '1 * * * 0' # Every sunday | ||
permissions: read-all | ||
jobs: | ||
BatchFuzzing: | ||
runs-on: ubuntu-latest | ||
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: | ||
language: c++ | ||
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: 3600 # 1 hour | ||
mode: 'batch' | ||
sanitizer: ${{ matrix.sanitizer }} | ||
# Optional but recommended: For storing certain artifacts from fuzzing. | ||
# See later section on "Git repo for storage". | ||
#storage-repo: https://${{ secrets.PERSONAL_ACCESS_TOKEN }}@github.com/LedgerHQ/fuzzers-corpus.git | ||
#storage-repo-branch: main # Optional. Defaults to "main" | ||
#storage-repo-branch-coverage: gh-pages # Optional. Defaults to "gh-pages". | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: ClusterFuzzLite PR fuzzing | ||
on: | ||
pull_request: | ||
paths: | ||
- '**' | ||
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: | ||
language: c++ | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
sanitizer: ${{ matrix.sanitizer }} | ||
# Optional but recommended: used to only run fuzzers that are affected | ||
# by the PR. | ||
# See later section on "Git repo for storage". | ||
#storage-repo: https://${{ secrets.PERSONAL_ACCESS_TOKEN }}@github.com/LedgerHQ/fuzzers-corpus.git | ||
#storage-repo-branch: main # Optional. Defaults to "main" | ||
#storage-repo-branch-coverage: gh-pages # Optional. Defaults to "gh-pages". | ||
- name: Run Fuzzers (${{ matrix.sanitizer }}) | ||
id: run | ||
uses: google/clusterfuzzlite/actions/run_fuzzers@v1 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
fuzz-seconds: 600 # 10 minutes | ||
mode: 'code-change' | ||
sanitizer: ${{ matrix.sanitizer }} | ||
# Optional but recommended: used to download the corpus produced by | ||
# batch fuzzing. | ||
# See later section on "Git repo for storage". | ||
#storage-repo: https://${{ secrets.PERSONAL_ACCESS_TOKEN }}@github.com/LedgerHQ/fuzzers-corpus.git | ||
#storage-repo-branch: main # Optional. Defaults to "main" | ||
#storage-repo-branch-coverage: gh-pages # Optional. Defaults to "gh-pages". | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
construct==2.10.61 | ||
pytest>=6.1.1,<7.0.0 | ||
ledgerwallet>=0.1.2 | ||
protobuf~=3.19 |