Skip to content

ci(fuzz): adopt ClusterFuzzLite for continuous fuzzing on PRs#102

Merged
peczenyj merged 1 commit into
develfrom
security/clusterfuzzlite
Jun 3, 2026
Merged

ci(fuzz): adopt ClusterFuzzLite for continuous fuzzing on PRs#102
peczenyj merged 1 commit into
develfrom
security/clusterfuzzlite

Conversation

@peczenyj
Copy link
Copy Markdown
Owner

@peczenyj peczenyj commented Jun 3, 2026

What

Wire the repo's three native Go fuzz targets into ClusterFuzzLite — the self-hosted OSS-Fuzz variant Google recommended after declining our OSS-Fuzz onboarding (google/oss-fuzz#15574, "too immature… large user base").

  • .clusterfuzzlite/project.yaml (language: go), Dockerfile on gcr.io/oss-fuzz-base/base-builder-go:v1, and build.sh compiling FuzzMatchAny, FuzzSplitCSV (internal/match) and FuzzTruncPad (internal/ui) via compile_native_go_fuzzer. The go-118-fuzz-build shim is go get-ed only inside the container — the repo's go.mod is untouched.
  • .github/workflows/cflite_pr.yml — PR-triggered code-change fuzzing (300s, address sanitizer), action pinned by commit SHA (884713a = v1, dereferenced from the annotated tag), top-level contents: read, path-filtered to Go/fuzz changes.
  • internal/match/fuzz_test.go — moved from external package match_test to package match: the go-118-fuzz-build rewrite turns the _test.go into a non-test file, and an external test package then clashes with the real package in the same directory (caught in the local container build).

Verification (run locally in the real OSS-Fuzz container)

  • All three fuzzers compile via the exact compile entrypoint the action uses.
  • All three run clean: fuzz_trunc_pad 64k+ execs/60s, match targets 1M+ execs/30s each.
  • First catch already banked: this setup found the pre-existing makeslice panic fixed in fix(ui): clamp column width to avoid makeslice panic on huge -width #101 within 5 seconds.
  • The ClusterFuzzLite PR fuzzing check on this very PR is the live end-to-end verification.

Follow-ups (tracked in #99)

  • Scheduled batch fuzzing + corpus persistence (needs a filestore decision)
  • A fuzz target for the real untrusted-input surface (internal/align.normalizeStruct)
  • Update the OpenSSF badge dynamic_analysis justification to cite continuous fuzzing in CI

Closes #99

🤖 Generated with Claude Code

Wire the repo's native Go fuzz targets (FuzzMatchAny, FuzzSplitCSV,
FuzzTruncPad) into ClusterFuzzLite, the self-hosted OSS-Fuzz variant
recommended after our OSS-Fuzz onboarding PR (google/oss-fuzz#15574)
was declined for project size:

- .clusterfuzzlite/{project.yaml,Dockerfile,build.sh}: build the three
  targets as libFuzzer binaries via compile_native_go_fuzzer on
  gcr.io/oss-fuzz-base/base-builder-go (the go-118-fuzz-build shim is
  go-getted only inside the container, never in the repo go.mod).
- .github/workflows/cflite_pr.yml: PR-triggered code-change fuzzing
  (300s, address sanitizer), action pinned by commit SHA,
  least-privilege permissions, path-filtered to Go/fuzz changes.
- internal/match/fuzz_test.go: move from package match_test to package
  match - compile_native_go_fuzzer's rewrite cannot handle an external
  test package alongside the non-test package in the same directory.

Verified locally in the real OSS-Fuzz container: all three fuzzers
compile and run clean (fuzz_trunc_pad 64k+ execs/60s after the #100
fix it surfaced, match targets 1M+ execs/30s each).

Closes #99

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@peczenyj peczenyj enabled auto-merge (squash) June 3, 2026 19:43
@peczenyj peczenyj self-assigned this Jun 3, 2026
@peczenyj peczenyj merged commit 2401e11 into devel Jun 3, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Adopt ClusterFuzzLite for continuous fuzzing in CI

1 participant