cve.bz

CVE-2026-40691 nlnetlabs unbound: Heap-based Buffer Overflow

7.5 highEPSS 0.3%

High (7.5) in nlnetlabs unbound. EPSS 0.3% estimated probability of exploitation activity in the next 30 days.

On this page
In Unbound 1.9.0 up to and including 1.25.1, when a DNSCrypt query is received over TCP, the routine that encrypts the reply in place fails to bound the reply length against the destination buffer size. The size clamp that protects the UDP path is not applied on the TCP path, so a reply larger than 65504 bytes is shifted forward by 48 bytes inside a buffer of capacity equal to 'msg-buffer-size', writing past the end of the heap allocation. A single malicious encrypted query crashes the resolver and lead to denial of service. This vulnerability needs Unbound to be compiled with DNSCrypt support ('--enable-dnscrypt') and the 'dnscrypt:' clause to be configured and enabled for the listening interfaces.

Severity

CVSS 3.1

7.5 high
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
EPSS
0.3% (unchanged from 0.3% a week ago; 0.3% 30 days ago) estimated probability of exploitation activity in the next 30 days; 22nd percentile. Scored 2026-11-15. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: yes · Technical impact: partial, assessed 2026-07-22. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWEs
CWE-122 Heap-based Buffer Overflow
CWE-787 Out-of-bounds Write
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2026-40691 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-40691?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-40691?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-40691 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Badge for a README or a site

CVE-2026-40691

An image that stays current: it is drawn from the data each time it is fetched (a host that proxies images, as GitHub does, may show its copy for a while). Markdown:

[![CVE-2026-40691](https://cve.bz/cve/badge/CVE-2026-40691.svg)](https://cve.bz/cve/CVE-2026-40691)

HTML:

<a href="https://cve.bz/cve/CVE-2026-40691"><img src="https://cve.bz/cve/badge/CVE-2026-40691.svg" alt="CVE-2026-40691"></a>

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
NLnet Labs Unboundfrom 1.9.0 before 1.25.2

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12unboundno fix listedDEBIAN-CVE-2026-40691
Debian13unbound1.26.1-0+deb13u1DEBIAN-CVE-2026-40691
Debian14unbound1.25.2-1DEBIAN-CVE-2026-40691
Ubuntu22.04:LTSunbound1.13.1-1ubuntu5.17UBUNTU-CVE-2026-40691 USN-8946-1
Ubuntu24.04:LTSunbound1.19.2-1ubuntu3.12UBUNTU-CVE-2026-40691 USN-8946-1
Ubuntu26.04:LTSunbound1.24.2-1ubuntu2.4UBUNTU-CVE-2026-40691 USN-8946-1
Ubuntu26.10unbound1.25.1-1ubuntu3.1UBUNTU-CVE-2026-40691 USN-8946-2
UbuntuPro:14.04:LTSunbound1.4.22-1ubuntu4.14.04.3+esm5USN-8946-1
UbuntuPro:16.04:LTSunbound1.5.8-1ubuntu1.1+esm5USN-8946-1
UbuntuPro:18.04:LTSunbound1.6.7-1ubuntu2.6+esm6UBUNTU-CVE-2026-40691 USN-8946-1
UbuntuPro:20.04:LTSunbound1.9.4-2ubuntu1.11+esm3UBUNTU-CVE-2026-40691 USN-8946-1
Red Hathummingbird:1unbound, unbound-libs, unbound-devel and 5 more0:1.25.2-0.1.hum1RHSA-2026:43588
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSS, Linux Enterprise High Performance Computing 15 SP5-ESPOS and 6 moreunbound1.25.2-150100.10.28.1SUSE-SU-2026:3884-1
SUSELinux Enterprise Module for Basesystem 15 SP7, Linux Enterprise Module for Package Hub 15 SP7, Linux Enterprise Server 15 SP6-LTSS and 1 moreunbound1.25.2-150600.23.19.1SUSE-SU-2026:3885-1
SUSELinux Enterprise Server 16.0, Linux Enterprise Server for SAP applications 16.0unbound1.25.2-160000.1.1SUSE-SU-2026:23215-1 SUSE-SU-2026:23226-1
SUSELinux Micro 6.0unbound1.25.2-1.1SUSE-SU-2026:23360-1
SUSELinux Micro 6.1unbound1.25.2-slfo.1.1_1.1SUSE-SU-2026:23349-1
SUSELinux Micro 6.2unbound1.25.2-160000.1.1SUSE-SU-2026:23050-1
openSUSELeap 16.0unbound1.25.2-160000.1.1openSUSE-SU-2026:21550-1
openSUSETumbleweedunbound1.25.2-1.1openSUSE-SU-2026:11380-1
Azure Linux3unbound1.25.2-1AZL-92949

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; Red Hat Security Data © Red Hat, Inc., CC BY 4.0; SUSE security data, CC BY 4.0; Microsoft's Azure Linux vulnerability data, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat · SUSE · openSUSE.

Red Hat

Red Hat rates this Important.

Red Hat's statement

This is an Important denial of service vulnerability affecting Unbound when built with DNSCrypt support. A remote attacker can trigger a heap overflow by sending a specially crafted DNSCrypt query over TCP, leading to a server crash and disruption of DNS resolution services. This vulnerability doesn't impact any supported the versions of unbound as shipped with Red Hat Enterprise Linux as it is not compiled with DNSCrypt support.

ProductPackageStateAdvisory
Red Hat Hardened Imagesunbound-main-1.25.2-0.1.hum1Fixed 2026-07-22RHSA-2026:43588
Red Hat Enterprise Linux 10unboundNot affected
Red Hat Enterprise Linux 6unboundNot affected
Red Hat Enterprise Linux 7unboundNot affected
Red Hat Enterprise Linux 8unboundNot affected
Red Hat Enterprise Linux 9unboundNot affected
Red Hat OpenShift Container Platform 4openshift/ose-rhel-coreos-8Not affected
Red Hat OpenShift Container Platform 4openshift/ose-rhel-coreos-9Not affected

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-40691.

Attack patterns (CAPEC)

  • CAPEC-92 Forced Integer Overflow Likelihood: High · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON