Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-19737 Overview
CVE-2026-19737 is a NULL pointer dereference [CWE-476] in the Zephyr RTOS i2s_esp32 driver. The i2s_esp32_trigger_check() function in drivers/i2s/i2s_esp32.c validates stream pointers only for the I2S_DIR_BOTH branch. The I2S_DIR_RX and I2S_DIR_TX branches read dev_cfg->rx.data->configured and dev_cfg->tx.data->configured without first checking that the stream pointers are non-NULL. On device instances that wire only one direction, invoking the unwired direction dereferences a NULL pointer in kernel mode and halts the system through the default fatal-error handler.
Critical Impact
An unprivileged user-mode thread granted access to the I2S device can trigger a kernel-mode load from address 0, producing a system-wide denial of service on affected Espressif RISC-V builds.
Affected Products
- Zephyr RTOS v4.4.0 (listed affected range) with CONFIG_USERSPACE enabled
- Espressif ESP32-C6 HPCORE builds that select CONFIG_RISCV_PMP when not built for MCUboot
- Any in-tree i2s_esp32 driver configuration where only one direction (RX or TX) is wired in devicetree, including worldsemi,ws2812-i2s LED strip usage
Discovery Timeline
- 2026-10-11 - CVE-2026-19737 published to NVD
- 2026-10-16 - Last updated in NVD database
Technical Details for CVE-2026-19737
Vulnerability Analysis
The defect is a missing NULL check in i2s_esp32_trigger_check(). The I2S_ESP32_STREAM_INIT() instantiation macro sets both .conf and .data to NULL for any direction the devicetree does not describe. The trigger-check function assumes both stream descriptors are present and dereferences dev_cfg->rx.data or dev_cfg->tx.data without validation. The read is a fixed load at offset 0 of the missing stream structure. There is no attacker-controlled offset, no write primitive and no information disclosure path, so impact is confined to availability.
i2s_trigger() is a Zephyr syscall. z_vrfy_i2s_trigger() in drivers/i2s/i2s_handlers.c validates only the device object and the presence of the trigger API pointer. The dir argument reaches the driver unvalidated. A user-mode thread that has been granted the I2S device can issue a single i2s_trigger() call naming the unwired direction and crash the kernel.
Root Cause
The I2S_DIR_BOTH branch of i2s_esp32_trigger_check() already guards against NULL stream pointers, but the I2S_DIR_RX and I2S_DIR_TX branches do not. The driver's other entry points (i2s_esp32_config_check(), i2s_esp32_config_get(), i2s_esp32_read(), i2s_esp32_write()) already perform the equivalent guard, so this was an isolated oversight. The unguarded dereference has existed since v4.2.0 and took its present form in v4.3.0.
Attack Vector
Exploitation requires local access with low privileges on a build that satisfies two conditions: CONFIG_USERSPACE is enabled and the user-mode thread has been granted the I2S device object. Among in-tree Espressif configurations, only RISC-V SoCs with CONFIG_RISCV_PMP can run user-mode threads, and v4.4.0 is the first release where that is buildable on the ESP32-C6 HPCORE. Xtensa targets do not support Zephyr userspace. In non-userspace builds, the bad direction can only be supplied by in-kernel application code.
return -ENOSYS;
}
} else if (dir == I2S_DIR_RX) {
+ if (!dev_cfg->rx.conf || !dev_cfg->rx.data) {
+ LOG_DBG("I2S_DIR_RX not supported");
+ return -ENOSYS;
+ }
configured = dev_cfg->rx.data->configured;
} else if (dir == I2S_DIR_TX) {
+ if (!dev_cfg->tx.conf || !dev_cfg->tx.data) {
+ LOG_DBG("I2S_DIR_TX not supported");
+ return -ENOSYS;
+ }
configured = dev_cfg->tx.data->configured;
} else {
LOG_DBG("Invalid dir: %d", dir);
Source: Zephyr commit 0d82dbbe. The patch adds the same pointer check the I2S_DIR_BOTH branch already performed and returns -ENOSYS for a direction the instance does not implement.
Detection Methods for CVE-2026-19737
Indicators of Compromise
- Unexpected kernel fatal-error exceptions on Espressif RISC-V devices referencing a load from address 0 inside i2s_esp32_trigger_check().
- System halts or watchdog resets correlated with user-mode threads that hold access to an I2S device object.
- Device telemetry showing abrupt termination of audio output or ws2812-i2s LED strip control.
Detection Strategies
- Audit Zephyr build configurations for CONFIG_USERSPACE=y combined with CONFIG_RISCV_PMP=y on ESP32-C6 HPCORE targets built outside MCUboot.
- Review devicetree entries for i2s_esp32 instances that wire only one direction, which exposes the unguarded dereference path.
- Statically scan application code and user-mode threads for i2s_trigger() call sites that pass a dir argument not matched by the devicetree configuration.
Monitoring Recommendations
- Capture kernel fault logs and symbolize backtraces that terminate in i2s_esp32_trigger_check() or i2s_esp32_trigger_stream().
- Enable fault-handler logging to persistent storage so post-mortem analysis can identify the faulting direction and caller.
- Track firmware version inventory across deployed Espressif devices to flag assets running Zephyr v4.4.0 without the patch.
How to Mitigate CVE-2026-19737
Immediate Actions Required
- Apply the upstream Zephyr fix in commit 0d82dbbe to drivers/i2s/i2s_esp32.c and rebuild affected firmware images.
- On fleets that cannot be patched immediately, disable CONFIG_USERSPACE or revoke user-mode thread access to the I2S device object.
- Validate that application code only calls i2s_trigger() with a dir value matching a direction wired in the devicetree.
Patch Information
The fix is published in Zephyr commit 0d82dbbe72f154de32cc45021a9f59d9a737246b and tracked in advisory GHSA-5g9q-h8wq-rrf3. The patch has also been merged to the v4.3-branch as hardening even though those releases are not listed as affected.
Workarounds
- Build firmware without CONFIG_USERSPACE so the unvalidated dir argument can only originate from trusted kernel code.
- Remove the I2S device from the set of objects granted to user-mode threads using Zephyr's k_object_access_grant() policy.
- Wrap application-level i2s_trigger() calls with a direction check derived from the devicetree configuration.
# Fetch and apply the upstream fix in a Zephyr workspace
cd zephyr
git fetch origin
git cherry-pick 0d82dbbe72f154de32cc45021a9f59d9a737246b
west build -b esp32c6_devkitc/esp32c6/hpcore <app>
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

