Commit fddc7c1ab8 for bind
commit fddc7c1ab87845cd8000e9b2c043c26d9e0a37ba
Author: Petr Špaček <pspacek@isc.org>
Date: Wed Nov 4 10:24:06 2026 +0000
Allow large RDATA to reach round-trip checks
The 1 KiB buffers caused valid larger records to return ISC_R_NOSPACE
before conversion checks ran.
Assisted-by: Codex:gpt-6
diff --git a/fuzz/dns_rdata_fromwire_text.c b/fuzz/dns_rdata_fromwire_text.c
index cf455b6825..769938bc4d 100644
--- a/fuzz/dns_rdata_fromwire_text.c
+++ b/fuzz/dns_rdata_fromwire_text.c
@@ -84,7 +84,11 @@ int
LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
isc_lex_t *lex = NULL;
isc_lexspecials_t specials;
- char totext[64 * 1044 * 4];
+ /*
+ * Room for 4x expansion of the largest RDATA, plus a full type bitmap
+ * with every type printed as the longest mnemonic and a separator.
+ */
+ static char totext[64 * 1044 * 4 + (11 + 1) * 65536];
dns_compress_t cctx;
dns_rdatatype_t rdtype;
dns_rdataclass_t rdclass;
@@ -96,9 +100,9 @@ LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) {
dns_rdatacallbacks_t callbacks;
isc_buffer_t source, target;
isc_result_t result;
- unsigned char fromtext[1024];
- unsigned char fromwire[1024];
- unsigned char towire[1024];
+ unsigned char fromtext[UINT16_MAX];
+ unsigned char fromwire[UINT16_MAX];
+ unsigned char towire[UINT16_MAX];
unsigned int classes = (sizeof(classlist) / sizeof(classlist[0]));
unsigned int flags;
diff --git a/fuzz/dns_rdata_fromwire_text.in/txt-1025 b/fuzz/dns_rdata_fromwire_text.in/txt-1025
new file mode 100644
index 0000000000..d28b4f3e38
Binary files /dev/null and b/fuzz/dns_rdata_fromwire_text.in/txt-1025 differ
diff --git a/fuzz/dns_rdata_fromwire_text.in/unknown-1025 b/fuzz/dns_rdata_fromwire_text.in/unknown-1025
new file mode 100644
index 0000000000..13b34ec5f5
Binary files /dev/null and b/fuzz/dns_rdata_fromwire_text.in/unknown-1025 differ