dnsmasq: enable the four C harnesses that have never built since 2021#59
Open
tc-agent wants to merge 2 commits into
Open
dnsmasq: enable the four C harnesses that have never built since 2021#59tc-agent wants to merge 2 commits into
tc-agent wants to merge 2 commits into
Conversation
Fuzzing Coverage ReportTested: project
Per-harness
Δ = (after − before) / before, to accommodate that denominators may change. "new" when before is 0; "deleted" when after is 0. |
tc-agent
force-pushed
the
dnsmasq-fix-broken-c-harnesses
branch
from
May 11, 2026 08:57
e388c11 to
4f22e53
Compare
tc-agent
force-pushed
the
dnsmasq-fix-broken-c-harnesses
branch
from
May 11, 2026 09:11
4f22e53 to
b5c2947
Compare
tc-agent
force-pushed
the
dnsmasq-fix-broken-c-harnesses
branch
from
May 11, 2026 09:29
b5c2947 to
7d376e6
Compare
tc-agent
force-pushed
the
master
branch
2 times, most recently
from
May 11, 2026 19:19
30a48e5 to
c6c45b4
Compare
tc-agent
force-pushed
the
master
branch
18 times, most recently
from
May 16, 2026 15:43
44e7379 to
ad807ee
Compare
tc-agent
force-pushed
the
master
branch
8 times, most recently
from
May 21, 2026 13:42
9a36aa8 to
6a4a93d
Compare
tc-agent
force-pushed
the
master
branch
3 times, most recently
from
May 27, 2026 06:33
6125235 to
e512e7e
Compare
tc-agent
force-pushed
the
dnsmasq-fix-broken-c-harnesses
branch
from
May 27, 2026 07:37
7d376e6 to
7e6bb12
Compare
tc-agent
force-pushed
the
master
branch
5 times, most recently
from
May 27, 2026 16:16
b5fd10c to
712a52f
Compare
tc-agent
force-pushed
the
dnsmasq-fix-broken-c-harnesses
branch
from
May 28, 2026 00:03
7e6bb12 to
1000fb4
Compare
tc-agent
force-pushed
the
master
branch
3 times, most recently
from
May 28, 2026 07:47
b952f62 to
02e947d
Compare
tc-agent
force-pushed
the
master
branch
3 times, most recently
from
May 28, 2026 18:05
af7f9a7 to
806b281
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Enables four libFuzzer harnesses in
projects/dnsmasq/that have beenin-tree since 2021 but never compiled by
build.sh. Thecopyright-2021 headers and lack of any working ASan crash artifact for
those harness names confirm they have been dormant. Fuzz Introspector
shows
fuzz_utilis the only running fuzzer today (baseline 1.65%,418/25,357 lines):
https://introspector.oss-fuzz.com/project-profile?project=dnsmasq
Supersedes the abandoned google/oss-fuzz#11779. Builds on
google/oss-fuzz#15091 (David Korczynski's
fuzz_utilrestoration); thisPR is additive and uses the same toolchain.
What changed
build.shnow produces five libFuzzer binaries:fuzz_utilfuzz_rfc1035extract_addresses,answer_request,extract_request,setup_reply,resize_packet,check_for_bogus_wildcard, etc.fuzz_authanswer_authfuzz_dhcpdhcp_replyfuzz_dhcp6dhcp6_replyHarness updates
signatures (
extract_addresses9 args,answer_request11 args,extract_request5 args,answer_auth6 args).fuzz_blockdata_cleanupwas declaredexternwith no definition;replaced with a static stub that calls
blockdata_init().gb_cleanup()was reordered to freedaemonlast (dnsmasq's freewrapper dereferences
daemon).fuzz_dhcp/fuzz_dhcp6invokedhcp_reply/dhcp6_replydirectly instead of
dhcp_packet/dhcp6_packet, which require areal socket for
recvmsg().init_daemonandfuzz_utilsubstitute a 1-char placeholder when afuzzed string would otherwise be empty, scoped to
gb_get_null_terminated(the helper called for strings stored indaemon->linked-list fields). This avoids hitting helpers that walkpast the NUL terminator on zero-length input — unrelated to the new
harnesses' attack surface.
dhcp_context->prefixis clamped to a valid IPv4/IPv6 prefix length.extract_nameoutput buffers are sized for NAME_ESCAPE 2× expansion.fuzz_recvmsg/fuzz_ioctl/syscall_datastubs removed.Seeds
Generated at build time by two Python scripts under
projects/dnsmasq/scripts/.Coverage
Local 5-minute
fuzz_for_pr(concurrent run, same primitive CI uses):Per-harness coverage:
fuzz_rfc1035: rfc1035.c 22%, cache.c 4%, util.c 10%fuzz_auth: auth.c 15.7%, rfc1035.c 8.7%fuzz_dhcp: rfc2131.c 11%, dhcp.c 17%fuzz_dhcp6: rfc3315.c 0.5%, dhcp6.c 4%fuzz_util: util.c 34%6.4× the Fuzz Introspector baseline.
Build infrastructure
-fuse-ld=lld. GNUldfails with"invalid or unhandled FORM value: 0x25" on DWARF-5 from newer clang.
fuzz_dhcp.options/fuzz_dhcp6.optionssetdetect_leaks=0because
dhcp_reply/dhcp6_replyretain allocations indaemon->linked lists across iterations.