CVE-2026-10653: Non-atomic `net_buf` reference counts cause double-free / free-list corruption under concurrent unref

Published Jun 30, 2026
·
Updated

The Zephyr netbuf library (lib/netbuf/buf.c) manipulated both of its reference counts -- the per-header buf->ref and the per-data-block refcount at the start of each variable/heap data allocation -- with plain non-atomic C operators (buf->ref++, if (--buf->ref > 0), if (--(refcount))).

The API is documented as self-synchronizing: callers may share one buffer across threads (e.g. via kfifo) and each holder independently calls netbufunref() with no surrounding lock. Under true concurrency (SMP, or single-core preemption between the non-atomic load and store while another context unrefs the same buffer), two holders can both observe the same prior reference value and both conclude they are the last reference.

For heap/variable-data pools (mempooldataunref/heapdataunref, used by zbus message subscribers, the IP stack RX/TX buffers when CONFIGNETBUFFIXEDDATASIZE=n, capture, wireguard, ISO-TP and usbip) this produces a double kheapfree()/kfree() of the same block -- heap-metadata corruption and a use-after-free on the heap-hardening poison pattern.

For the per-header refcount the buffer is returned to the pool free LIFO twice for any pool type (including fixed-data pools used by Bluetooth and networking), corrupting the free list so a later allocation hands the same buffer to two owners.

The fix converts both refcounts to atomicinc/atomicdec (overlaying buf->ref in an atomict-sized union and changing the data-block refcount from uint8t to atomict).

Impact is gated on genuine concurrency and on an application architecture that shares one buffer among multiple independent unref'ers; the trigger is a refcount/timing race rather than packet content, so an external attacker has at most weak indirect influence over the race window. Affects all Zephyr releases through v4.4.0.

This fix is not being backported to v3.7-branch (LTS). The backport was attempted and closed unmerged (#111181): the v3.7 networking tree has diverged from main, and the new atomic word-packing -- together with the assertions it adds -- turns pre-existing v3.7-only reference-counting defects elsewhere in the stack into hard faults, so landing the change faithfully would mean pulling an open-ended set of additional v3.7-only fixes into an LTS branch. v3.7 remains affected. Applications on v3.7 that share one netbuf across threads should serialize their own netbufunref() calls rather than rely on the documented self-synchronizing behaviour. The fix is on main and has been backported to v4.3-branch (#110852) and v4.4-branch (#110853).

Affected Software

2 affected components
Zephyr net_buf library<=4.4.0
zephyrproject zephyr>=2.7.0<=4.4.1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade Zephyr net_buf (lib/net_buf/buf.c) to a version that resolves this vulnerability.

    Patch #110852
  2. Upgrade

    Upgrade Zephyr net_buf (lib/net_buf/buf.c) to a version that resolves this vulnerability.

    Patch #110853
  3. Configuration

    On v3.7 and any affected releases, ensure each application that shares one net_buf across threads serializes its own net_buf_unref() calls (rather than relying on documented self-synchronizing behaviour); independently shared unref callers without surrounding lock can trigger concurrent refcount races.

    Zephyr applications using net_buf net_buf_unref call synchronization = serialize per-thread unref() calls for a shared net_buf

Event History

Jun 30, 2026
CVE Published
via MITRE·04:20 PM
Data Sourced
via MITRE·04:20 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·05:16 PM
RemedyDescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2026-10653?

The severity of CVE-2026-10653 is medium with a score of 6.4.

2

What types of vulnerabilities are associated with CVE-2026-10653?

CVE-2026-10653 is associated with double free and use after free vulnerabilities.

3

How does CVE-2026-10653 occur in the Zephyr net_buf library?

CVE-2026-10653 occurs due to non-atomic reference counts being manipulated in a way that leads to double-free or free-list corruption.

4

What is the risk associated with CVE-2026-10653?

The risk associated with CVE-2026-10653 is rated at 51, indicating potential exploitation could lead to significant impact.

5

What functions are affected by CVE-2026-10653 in the net_buf library?

CVE-2026-10653 affects the functions that handle reference counts during variable and heap data allocation in the net_buf library.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203