CVE-2026-78118: race in zephyrproject zephyr
Description
CVE-2026-78118 is a race condition vulnerability in the Zephyr kernel's wait queue handling on SMP (multi-CPU) systems. It arises because the kernel helper z_waitq_head() reads the head of a thread wait queue without holding the necessary scheduler spinlock, leading to potential use-after-free and out-of-bounds writes. This can cause scheduler state corruption or kernel crashes. Exploitation requires local code execution on a multi-CPU system and precise timing. The vulnerability affects Zephyr versions from 2.2.0 up to but not including 4.5.0.
CVSS v3.1
Score 7.0high
Affected software
zephyrproject
zephyr
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability exists in the Zephyr kernel's z_waitq_head() helper, which reads the head of a thread wait queue without holding the scheduler spinlock (_sched_spinlock) that serializes wait-queue mutations on SMP systems. The problematic call site is z_timer_expiration_handler(), which holds only the timer subsystem lock (timer_lock) while accessing timer->wait_q and manipulating threads. Concurrent removal of the last waiter on another CPU can cause sys_dlist_peek_head() to return invalid pointers, such as the list sentinel or freed thread objects. Subsequent calls to unpend_thread_no_timeout() and arch_thread_return_value_set() then perform unsafe memory operations, resulting in out-of-bounds and use-after-free writes in supervisor context and scheduler corruption. The race can be triggered by unprivileged user-mode threads via system calls like k_timer_start(), k_timer_status_sync(), k_thread_create(), and k_thread_abort(). Exploitation is constrained by the need for multi-CPU builds (CONFIG_MP_MAX_NUM_CPUS > 1) and a narrow timing window, typically causing kernel crashes rather than controlled corruption. The fix involves splitting z_waitq_head() into a locked variant and ensuring the timer expiration handler's operations occur under a single scheduler spinlock region.
Potential Impact
Successful exploitation can lead to out-of-bounds and use-after-free writes in kernel supervisor context, causing scheduler state corruption or kernel crashes. The vulnerability allows an unprivileged local user-mode thread to race against kernel data structures, potentially destabilizing the system. However, exploitation requires multi-CPU hardware and precise timing, making controlled exploitation difficult. The CVSS score of 7.0 reflects high impact on confidentiality, integrity, and availability.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. The described fix involves modifying the kernel code to properly acquire the scheduler spinlock when accessing wait queues and consolidating timer expiration handler operations under this lock. Until an official patch is available, avoid running untrusted local code on multi-CPU Zephyr systems or disable multi-CPU support if feasible.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- zephyr
- Date Reserved
- 2026-08-22T20:23:01.098Z
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 6ad905114d27ba8daadca2f8
Added to database: 10/21/2026, 18:31:45 UTC
Last enriched: 10/21/2026, 18:45:20 UTC
Last updated: 10/21/2026, 18:46:14 UTC
Views: 5
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.