forked from QuorumProof/QuorumProof
-
Notifications
You must be signed in to change notification settings - Fork 0
83 lines (70 loc) · 2.01 KB
/
Copy pathfuzz.yml
File metadata and controls
83 lines (70 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
name: Fuzzing
on:
push:
branches: [main, develop]
paths:
- "fuzz/**"
- "contracts/**"
- ".github/workflows/fuzz.yml"
pull_request:
branches: [main]
paths:
- "fuzz/**"
- "contracts/**"
schedule:
# Run daily at 2 AM UTC
- cron: "0 2 * * *"
env:
CARGO_TERM_COLOR: always
jobs:
fuzz:
runs-on: ubuntu-latest
strategy:
matrix:
fuzz_target:
- fuzz_verification_functions
- fuzz_bbs_plus_operations
- fuzz_zk_verifier
- fuzz_credential_issuance
- fuzz_batch_operations
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- name: Cache cargo
uses: Swatinem/rust-cache@v2
- name: Install cargo-fuzz
run: cargo install cargo-fuzz --locked
- name: Run fuzz target (${{ matrix.fuzz_target }}) for 30 seconds
run: |
cd fuzz
cargo +nightly fuzz run ${{ matrix.fuzz_target }} -- -max_total_time=30 -timeout=10
continue-on-error: true
fuzz-nightly:
runs-on: ubuntu-latest
if: github.event_name == 'schedule'
strategy:
matrix:
fuzz_target:
- fuzz_verification_functions
- fuzz_bbs_plus_operations
- fuzz_zk_verifier
- fuzz_credential_issuance
- fuzz_batch_operations
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- name: Cache cargo
uses: Swatinem/rust-cache@v2
- name: Install cargo-fuzz
run: cargo install cargo-fuzz --locked
- name: Run extended fuzzing (${{ matrix.fuzz_target }}) for 5 minutes
run: |
cd fuzz
cargo +nightly fuzz run ${{ matrix.fuzz_target }} -- -max_total_time=300 -timeout=10
continue-on-error: true
- name: Upload crash artifacts
if: failure()
uses: actions/upload-artifact@v4
with:
name: fuzz-crashes-${{ matrix.fuzz_target }}
path: fuzz/artifacts/