Impact
The Zephyr RTOS kernel contains a race condition in the wait‑queue helper z_waitq_head() when used from the timer expiration handler on SMP systems. Because the helper was executed without holding the scheduler spinlock, an unprivileged user thread can orchestrate a narrow timing window where the last waiter is removed on another CPU, causing sys_dlist_peek_head() to return either a sentinel pointer or a pointer to a freed thread. The handler then performs unpend_thread_no_timeout(), sys_dlist_remove(), and arch_thread_return_value_set() using that corrupted pointer, resulting in out‑of‑bounds or use‑after‑free writes in supervisor context and corrupting scheduler state. The primary impact is a kernel crash or unpredictable behaviour; a milder outcome is improper thread wake‑up signals. This flaw is identified as a race condition on kernel data structures (CWE‑362).
Affected Systems
All Zephyr RTOS releases that enable SMP (CONFIG_MP_MAX_NUM_CPUS > 1) and use the affected wait‑queue logic before the patch referenced in commit a9b21f. No explicit version range is provided, but the flaw exists in builds that have not incorporated the recent commit fixing the locking. Boards and applications compiled from Zephyr sources prior to this commit are potentially affected if they run on multi‑processor configurations.
Risk and Exploitability
The CVSS score is 7.0, indicating a high severity. The EPSS score is not available, and the vulnerability is not listed in CISA’s KEV catalog. Exploitation requires a multi‑CPU build, local code execution from an unprivileged thread, and precise timing to induce the race; thus the practical result is likely a kernel crash rather than deliberate corruption. The attack vector is local, with attacker control limited to user‑mode code running on the same device. Overall, the risk is moderate to high for systems with SMP enabled, particularly those exposed to untrusted user processes.
OpenCVE Enrichment