diff options
| author | Abhishek Bachiphale <Abhishek.Bachiphale@windriver.com> | 2026-05-18 22:43:31 +0530 |
|---|---|---|
| committer | Khem Raj <khem.raj@oss.qualcomm.com> | 2026-05-20 21:18:30 -0700 |
| commit | a53328688a239e97b8383ffbfd7b4b4eca108d73 (patch) | |
| tree | bb83d7aeea464971800c4d73cd923f14d971a5c3 /meta-networking/recipes-support/dnsmasq/files | |
| parent | 47e9739586748a60428a116c0dcd761a2f648588 (diff) | |
| download | meta-openembedded-a53328688a239e97b8383ffbfd7b4b4eca108d73.tar.gz | |
dnsmasq: fix CVE-2026-2291
dnsmasqs extract_name() function can be abused to cause a heap buffer
overflow, allowing an attacker to inject false DNS cache entries,
which could result in DNS lookups to redirect to an attacker-controlled
IP address, or to cause a DoS.
Reference:
[ https://nvd.nist.gov/vuln/detail/CVE-2026-2291 ]
Signed-off-by: Abhishek Bachiphale <Abhishek.Bachiphale@windriver.com>
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
Diffstat (limited to 'meta-networking/recipes-support/dnsmasq/files')
| -rw-r--r-- | meta-networking/recipes-support/dnsmasq/files/CVE-2026-2291.patch | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/meta-networking/recipes-support/dnsmasq/files/CVE-2026-2291.patch b/meta-networking/recipes-support/dnsmasq/files/CVE-2026-2291.patch new file mode 100644 index 0000000000..6e42f32136 --- /dev/null +++ b/meta-networking/recipes-support/dnsmasq/files/CVE-2026-2291.patch | |||
| @@ -0,0 +1,37 @@ | |||
| 1 | commit ec2fbfbbdaa7d7db1c707dce26ce1a37cfe09660 | ||
| 2 | Author: Simon Kelley <simon@thekelleys.org.uk> | ||
| 3 | Date: Fri Apr 10 16:29:31 2026 +0100 | ||
| 4 | |||
| 5 | Fix buffer overflow in struct bigname. CVE-2026-2291 | ||
| 6 | |||
| 7 | All buffers capable of holding a domain name should be | ||
| 8 | at least MAXDNAME*2 + 1 bytes long, where MAXDNAME is the maximum | ||
| 9 | size of a domain name. The accounts for the trailing zero and the | ||
| 10 | fact that some characters are escaped in the internal representation | ||
| 11 | of a domain name in dnsmasq. | ||
| 12 | |||
| 13 | The declaration of struct bigname get this wrong, with the effect | ||
| 14 | that a remote attacker capable of asking DNS queries or answering DNS | ||
| 15 | queries can cause a large OOB write in the heap. | ||
| 16 | |||
| 17 | This was first spotted by Andrew S. Fasano. | ||
| 18 | |||
| 19 | CVE: CVE-2026-2291 | ||
| 20 | |||
| 21 | Upstream-Status: Backport [ https://thekelleys.org.uk/gitweb/?p=dnsmasq.git;a=commit;h=014e909f787e808bb35daa546d3f8f3663918de2 ] | ||
| 22 | |||
| 23 | Signed-off-by: Abhishek Bachiphale <Abhishek.Bachiphale@windriver.com> | ||
| 24 | |||
| 25 | diff --git a/src/dnsmasq.h b/src/dnsmasq.h | ||
| 26 | index 254bacd..58be09f 100644 | ||
| 27 | --- a/src/dnsmasq.h | ||
| 28 | +++ b/src/dnsmasq.h | ||
| 29 | @@ -479,7 +479,7 @@ struct interface_name { | ||
| 30 | }; | ||
| 31 | |||
| 32 | union bigname { | ||
| 33 | - char name[MAXDNAME]; | ||
| 34 | + char name[(2*MAXDNAME) + 1]; | ||
| 35 | union bigname *next; /* freelist */ | ||
| 36 | }; | ||
| 37 | |||
