Skip to content

ci: nightly libFuzzer targets for the byte-facing parsers - #64

Merged
moveeeax merged 1 commit into
masterfrom
ci/fuzzing
Aug 23, 2026
Merged

ci: nightly libFuzzer targets for the byte-facing parsers#64
moveeeax merged 1 commit into
masterfrom
ci/fuzzing

Conversation

@moveeeax

Copy link
Copy Markdown
Owner

Four libFuzzer harnesses over the parsers that eat network bytes, with oracles (not just no-crash): parse_traceparent (canonical output + format→parse round-trip), parse_decimal_to_cents (exact cents round-trip), config placeholder expansion (deterministic env), public-path matching + metrics path normalization (rooted, idempotent). Built -fsanitize=fuzzer,address,undefined -fno-sanitize-recover=all, curated seed corpora.

The clang-vs-vcpkg problem solved honestly: fuzzers never link app_core or see the vcpkg toolchain. The fuzzed parsers were split into std-only TUs by verbatim moves (TraceOtel out of Trace, PayPalParse out of the curl TU, ConfigExpand free functions, PathNormalize out of the drogon header) — the nightly needs only apt install clang nlohmann-json3-dev. Docs frame this as a tripwire: a fuzzed parser regaining heavy includes breaks the fuzz build by design. Top-level CMake diff is inert at ENABLE_FUZZERS=OFF.

.github/workflows/fuzz-nightly.yml: nightly cron + dispatch (seconds_per_target), growing corpus in actions/cache (saved even on crash via if: always() + run-id keys), crash ⇒ red job + reproducer artifact.

Proven locally: full fuzz CMake configure+build under clang 17; all four targets ran 15 s each (0.6M–7.4M execs, zero findings); every touched TU clang-syntax-checks; all gates + selftest 19/19 + clang-format dry-run clean. GCC/vcpkg linker truth for the verbatim splits = this CI run; a workflow_dispatch of Fuzz nightly right after merge is the follow-through.

@moveeeax
moveeeax merged commit b5263de into master Aug 23, 2026
11 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.

1 participant