CVE-2026-100374: Missing user buffer validation in SMBus block read and block process call syscalls allows kernel memory writes
The system call verification handlers for smbusblockread() and smbusblockpcall() in drivers/smbus/smbushandlers.c (zvrfysmbusblockread() and zvrfysmbusblockpcall()) validated the device object, the count pointers and (for process call) the send buffer, but never validated the receive buffer (buf / rcvbuf). The call then proceeds into the driver implementation, which runs in supervisor mode and writes the bytes received from the SMBus peripheral through that pointer.
A user-mode thread on a system built with CONFIGUSERSPACE that has been granted access to an SMBus device object can pass an arbitrary address, including kernel data or another thread's memory, as the receive buffer. The driver then writes up to SMBUSBLOCKBYTESMAX (32) bytes of peripheral-supplied data there (the STM32 driver writes as many bytes as the peripheral's length byte announces, up to 255). The address is fully attacker-chosen; the written content comes from the bus and is typically influenceable by the caller through the choice of peripheral and command, or by first writing data to a device that echoes it back.
This breaks the user/kernel isolation boundary: it gives an unprivileged thread a kernel-memory write primitive usable for privilege escalation, or at minimum to corrupt kernel state or crash the system. The fix adds KSYSCALLMEMORYWRITE() checks of the receive buffer for the documented worst case, SMBUSBLOCKBYTESMAX. Systems without CONFIGUSERSPACE are not affected.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In z_vrfy_smbus_block_read() and z_vrfy_smbus_block_pcall() in drivers/smbus/smbus_handlers.c, validate the receive buffer with K_SYSCALL_MEMORY_WRITE() for SMBUS_BLOCK_BYTES_MAX bytes before calling the driver.
Event History
Frequently Asked Questions
Which deployments are exposed to exploitation?
Exposure requires a system built with CONFIG_USERSPACE where a user-mode thread has been granted access to an SMBus device object. Systems without that user-mode access path are not described as exploitable by this issue.
What does an attacker need to exploit the flaw?
The attacker needs to run a user-mode thread with access to an SMBus device object and invoke the affected block-read or block-process-call interface. They can supply an arbitrary receive-buffer address and need SMBus peripheral data that can be influenced through the selected peripheral and command, or by writing data to a device that echoes it back.
What is the practical impact of a successful exploit?
A user-mode thread can cause supervisor-mode driver code to write peripheral-supplied bytes to attacker-chosen kernel or other-thread memory, breaking user/kernel isolation. The normal maximum is 32 bytes, while the STM32 driver may write up to 255 bytes according to the peripheral length byte.
How can I identify potentially affected systems?
Identify builds that enable CONFIG_USERSPACE, expose SMBus device objects to user-mode threads, and permit those threads to use SMBus block read or block process call operations. The affected verification handlers are z_vrfy_smbus_block_read() and z_vrfy_smbus_block_pcall() in drivers/smbus/smbus_handlers.c.