Skip to content

Executive Summary

A heap buffer overflow vulnerability was found in Dnsmasq, which was fixed in versions 2.92rel2 and 2.93 on May 11, 2026, and assigned CVE-2026-2291. The vulnerability originated from a change in release 2.73, where handling domain names with '.' or '/000' within labels introduced changes to the format used for C strings during processing. This modification resulted in the use of escape sequences that potentially doubled the required storage length. The issue specifically affected Dnsmasq's caching system, which uses a 1,025-byte buffer called bigname for storing cached resource records. An unsafe use of strcpy() in the reallyinsert function allowed heap buffer overflows when domain names exceeded the size of the allocated buffers, particularly in the bigname cache. Exploitation required setting up specific DNS responses to chain memory allocations on the free list and overwrite a pointer to achieve remote code execution by targeting a function pointer in ld.so.

Facts Only

* The vulnerability was fixed in Dnsmasq versions 2.92rel2 and 2.93 on May 11, 2026, under CVE-2026-2291.
* The vulnerability was introduced in release 2.73.
* The change involved handling domain names with '.' or '/000' within labels in DNSSEC mode.
* Processing DNS replies converts domain names to C strings using modified formatting that included escape sequences, potentially doubling storage requirements.
* The caching system uses a 1,025-byte buffer named bigname for storing resource records.
* An unsafe strcpy() call in the reallyinsert function was the root cause of the heap overflow.
* This overflow occurs when escaped domain names exceed the size of the bigname buffer.
* Exploitation involved chaining DNS requests to manipulate buffers on the free list and overwriting a pointer in ld.so to gain EIP control.

Full Take

The narrative highlights a critical failure at the intersection of protocol parsing, memory management, and system-level execution control within networking software. The transition from standard string handling to specialized escape sequences introduces subtle complexity that is not adequately guarded by existing memory safety checks. The reliance on an unsafe function like strcpy() operating on dynamically sized buffers (bigname) demonstrates a systemic gap in enforcing boundaries, even when specific structures are introduced for optimization, like the caching mechanism.
The exploitation path reveals a layered attack: first leveraging an information leak/write primitive to corrupt the heap metadata (the free list pointer), followed by controlling object allocation and subsequent copying to achieve arbitrary write primitives. This pattern suggests that low-level parsing logic, when interacting with memory allocators, becomes a high-value target for advanced exploitation. The finding underscores the necessity of rigorously auditing code paths where string length is manipulated before use, especially in systems that bridge external protocol data with internal memory structures.
What are the assumptions underlying the safety mechanisms in this specific context? If caching behavior necessitates variable-length storage augmentation (like bigname), why was the bounds checking bypassed across the entire operation? What does the presence of N-Day research focus on—the timely patching vs. the window of exposure?

From the original · Exodus Intelligence

By David Barksdale In this blog post, we discuss a heap buffer overflow vulnerability that we found in Dnsmasq. This vulnerability was fixed in version 2.92rel2 and 2.93 on 11 May 2026 and assigned CVE-2026-2291.
Read the full story at blog.exodusintel.com

Sentinel — Human

Confidence

The text reads like an expert-written, highly specific technical exploit write-up, exhibiting high internal consistency that points toward human expertise rather than generic synthetic generation.

Signals Detected
low severity: Clear, technical narrative flow with highly specific code snippets and step-by-step exploit description.
low severity: Highly dense, specialized vocabulary typical of deep technical writing, contrasting with the blog structure.
low severity: The detailed exposition of the vulnerability and exploit chain seems internally consistent, suggesting direct source knowledge rather than generic LLM pattern matching.
Human Indicators
Presence of specific commit hashes, file paths (src/cache.c), precise memory addresses, and raw packet data strongly suggests authorship by someone with direct access to the code or deep forensic knowledge.
The narrative shifts from technical proof to commercial promotion (Exodus Intelligence) which is a common pattern in vulnerability disclosure blogs.
Dnsmasq DNS Remote Heap Buffer Overflow | Huntaegis