Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAttacker establishes TCP connections from adjacent network
-
DeliveryLow-privilege user invokes 'net conn' shell command triggering net_tcp_foreach()
-
ExploitAttacker sends TCP RST/FIN to drive concurrent tcp_conn_release()
-
Executiontcp_conn_release() frees cached next-pointer slab during unlocked callback window
-
PersistIterator dereferences freed memory
-
ImpactSystem crash (DoS) or attacker-influenced callback execution
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Memory lifecycle management
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Privilege Escalation The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Two simultaneous conditions are required. First, net_tcp_foreach() must be executing: this is reached either (a) when a low-privilege user runs the 'net conn' network shell command (requiring CONFIG_NET_SHELL to be enabled, which is a non-default build option in production hardened builds, and requiring shell/CLI access on the device), or (b) when a network interface goes down, triggering net_tcp_close_all_for_iface(). Second, a remote peer on the same adjacent network segment (LAN, VLAN, or direct link - AV:A precludes internet-routed attack) must simultaneously cause a TCP connection's reference count to drop to zero by sending a FIN or RST - this is achievable with ordinary TCP traffic and requires no special attacker capability beyond network adjacency. The race window between these two events must be won (AC:H), making reliable exploitation timing-dependent rather than deterministic. Exploitation is further limited by the PR:L requirement: shell access or equivalent local privilege is needed to trigger the iterator path. The assigned CVSS vector marks C:N, but the description states that slab reuse can lead to information disclosure - defenders should treat confidentiality impact as a realistic secondary outcome, not a confirmed-absent risk. |
| Impact | The assigned CVSS 3.1 score of 4.8 (Medium) with vector AV:A/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H accurately reflects the significant exploitation barriers: the attacker must be on an adjacent network segment (AV:A, ruling out internet-scale scanning), must win a timing-dependent race condition (AC:H), and must have low-privilege access to invoke the shell command or trigger an interface-down event (PR:L). These three compounding factors make opportunistic mass exploitation implausible. However, the C:N metric warrants scrutiny - the CVE description explicitly identifies potential information disclosure if the freed slab slot is reallocated before the callback dereferences it; the CVSS vector appears to understate this risk. No EPSS data was supplied, no KEV listing exists, and no public exploit code has been identified - consistent with the high exploitation complexity. In constrained embedded environments (RTOS-based IoT devices, sensor nodes, industrial controllers) where Zephyr TCP networking is enabled and adjacent-network isolation is weak, the DoS impact is the dominant concern: crashing the TCP stack on a resource-constrained device may require a physical reboot with no automated recovery. |
| Exploit ScenarioDerived | An attacker sharing a LAN segment with a Zephyr device establishes multiple TCP connections to it, then sends rapid RST packets to drive connection teardowns, while a low-privilege user (or automated diagnostic process) concurrently invokes the 'net conn' shell command, triggering net_tcp_foreach(). If the RST-driven tcp_conn_release() frees the iterator's cached next-pointer during the unlocked callback window, the iterator dereferences freed slab memory - either crashing the Zephyr device (requiring physical reboot) or, if the slab slot was reallocated for a new connection the attacker partially controls, causing the diagnostic callback to operate on attacker-influenced data. No public exploit code has been identified at time of analysis. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 15, 2026
Use-after-free in Zephyr RTOS's native TCP2 stack allows a concurrent connection teardown - triggered by ordinary TCP traffic from an adjacent-network peer - to invalidate a cached iterator pointer in net_tcp_foreach(), crashing the system or causing the iterator callback to operate on attacker-influenced reallocated memory. All Zephyr releases from the TCP2 stack introduction in 2020 through v4.4.0 (inclusive) are affected. No public exploit has been identified at time of analysis and no CISA KEV listing exists; the primary real-world risk is denial of service against embedded or IoT devices with TCP networking and shell access exposed on an adjacent network segment.
RemediationAI
Apply the upstream fix from commit cd85e0e890ab89815c4cbc0a8fbc03a3efa84dc2 (https://github.com/zephyrproject-rtos/zephyr/commit/cd85e0e890ab89815c4cbc0a8fbc03a3efa84dc2), which restructures locking in tcp_conn_release() and net_tcp_foreach() to eliminate the race window. A specific tagged patched release version has not been independently confirmed - only the upstream commit is available at time of analysis; integrators building from the Zephyr repository should cherry-pick or rebase past this commit. Until patched, the most impactful compensating control is disabling the Zephyr network shell at build time (set CONFIG_NET_SHELL=n), which removes the 'net conn' command - one of the two confirmed entry points into net_tcp_foreach() - with no functional trade-off for production (non-diagnostic) builds. The second entry point, net_tcp_close_all_for_iface() triggered on interface-down, cannot be disabled without broader impact; restrict who can trigger interface state changes instead. Additionally, enforce strict adjacent-network segmentation (e.g., VLAN isolation, port-level access control) to limit the pool of peers able to initiate the TCP teardown side of the race. Refer to the GitHub advisory at https://github.com/zephyrproject-rtos/zephyr/security/advisories/GHSA-6c57-xfhw-j26x for vendor guidance.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Zephyr's TCP2 stack (subsys/net/ip/tcp.c, CPE cpe:2.3:a:zephyrproject:zephyr:*:*:*:*:*:*:*:*) maintains a global singly-linked list of TCP connections protected by tcp_lock (a k_mutex). The function net_tcp_foreach() iterates this list using SYS_SLIST_FOR_EACH_CONTAINER_SAFE, which caches a pointer to the next list node before each iteration step. Prior to the fix, net_tcp_foreach() dropped tcp_lock before invoking the per-connection callback and reacquired it afterward, creating an unlocked window. Concurrently, tcp_conn_release() - invoked from the dedicated TCP work-queue thread when a connection's reference count reaches zero (e.g., remote FIN or RST) - unlinks the connection from the global list and calls k_mem_slab_free() on the connection object. If this teardown races against the iterator's cached 'next' pointer, the iterator advances into freed slab memory that may have been reallocated - a textbook CWE-416 (Use After Free). The commit diff confirms the fix: tcp_conn_release() now performs teardown under tcp_lock, and net_tcp_foreach() holds tcp_lock continuously across the callback, eliminating the race window.
Know when Zephyr gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:A/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
Adjacent vector and high complexity confirmed by race condition; PR:L for shell requirement; C:L rather than C:N because description explicitly identifies information disclosure via slab reuse as a realistic outcome.
Primary rating from Vendor (zephyr).
CVSS VectorNVD
Lifecycle Timeline
1DescriptionNVD
Zephyr's native TCP stack iterates the global connection list in net_tcp_foreach() (subsys/net/ip/tcp.c) using the SYS_SLIST_FOR_EACH_CONTAINER_SAFE macro, which caches a pointer to the next list node. Prior to this fix the function released tcp_lock while invoking the per-connection callback and re-acquired it afterwards. During that window a concurrent tcp_conn_release(), running on the dedicated TCP work-queue thread when a connection's reference count drops to zero (e.g. a remote peer closing or resetting the connection), can remove and k_mem_slab_free() the cached next connection. When the iterator advances it dereferences the freed (and possibly reallocated) slab memory - a use-after-free that can crash the system (denial of service) and, if the slot has been reused, cause the callback to operate on an attacker-influenced object (potential information disclosure or further fault). net_tcp_foreach() is reached in production via the 'net conn' network shell command and via net_tcp_close_all_for_iface() on interface-down; the freeing side is driven by ordinary TCP traffic. The fix moves the connection/context teardown in tcp_conn_release() inside the tcp_lock critical section and keeps tcp_lock held across the callback in net_tcp_foreach(). The defect was introduced with the modern (TCP2) stack in 2020 and affects releases up to and including v4.4.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Use-after-free vulnerabilities occur when a program continues to access memory through a pointer after that memory has been deallocated.
Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.
Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.
Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.
Potential off-by-one buffer overflow vulnerability in the Zephyr fuse file system. Rated critical severity (CVSS 10.0),
An out-of-bounds write in the Zephyr RTOS DNS resolver (dns_unpack_name()) lets a crafted DNS response corrupt memory on
Possible variant of CVE-2021-3434 in function le_ecred_reconf_req. Rated critical severity (CVSS 9.8), this vulnerabilit
Unchecked user input length in /subsys/net/l2/wifi/wifi_shell.c can cause buffer overflows. Rated critical severity (CVS
Potential buffer overflow vulnerability in the Zephyr CAN bus subsystem. Rated critical severity (CVSS 9.8), this vulner
Integer Underflow in 6LoWPAN IPHC Header Uncompression in Zephyr. Rated critical severity (CVSS 9.8), this vulnerability
Buffer overflow in Zephyr USB DFU DNLOAD. Rated critical severity (CVSS 9.8), this vulnerability is remotely exploitable
DOS: Incorrect 802154 Frame Validation for Omitted Source / Dest Addresses. Rated critical severity (CVSS 9.8), this vul
zephyr-rtos version 1.12.0 contains a NULL base pointer reference vulnerability in sys_ring_buf_put(), sys_ring_buf_get(
Potential buffer overflow vulnerabilities n the Zephyr Bluetooth subsystem. Rated critical severity (CVSS 9.6), this vul
The documentation specifies that the BT_GATT_PERM_READ_LESC and BT_GATT_PERM_WRITE_LESC defines for a Bluetooth characte
Potential buffer overflows in the Bluetooth subsystem due to asserts being disabled in /subsys/bluetooth/host/hci_core.c
EUVD-2026-36727
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB