Researchers at Drivesec revealed yesterday that a manipulated USB device possesses the capability to execute arbitrary commands as the root user on a Linux system without requiring any user interaction, such as logging in, mounting a filesystem, or clicking anything.
This vulnerability, termed "USB2Shell," resides within the Linux kernel, specifically during the automatic scanning process that occurs the instant a USB storage device is connected. The exploit functions because the kernel processes the device before any user-space activity takes place.
This discovery follows a recent proliferation of vulnerabilities, including PHP2Shell, Java4Shell, wp2shell, and KindaRails2Shell, which are remote flaws present in widely utilized software. USB2Shell presents a physical manifestation of this threat: instead of requiring a specially crafted network request, an adversary simply inserts a specially crafted USB device.
Numerous Linux systems possess accessible USB ports, including those found in automotive infotainment and telematics units, electric vehicle chargers, point-of-sale terminals, kiosks, in-flight entertainment systems, industrial Human-Machine Interfaces (HMIs), and smart-home hubs. A system becomes susceptible when these conditions are met: no user input or mounting action is necessary, and the vulnerability triggers during the routine device scanning procedure.
On Android platforms, the issue manifests as a data leakage; however, kernels version 6.6 and newer are impacted, allowing the device to retrieve kernel stack contents. Nevertheless, the builds examined, such as Android GKI and the Samsung Galaxy A16 shipping kernel, incorporate compiler bounds checks which successfully contain the write operation within the designated buffer.
To assess exposure, one can utilize the provided checker script: curl -fsSLO https://usb2shell.com/tools/usb2shell-check.sh less usb2shell-check.sh sh usb2shell-check.sh. If this checker indicates a vulnerability in the kernel, system operators should consult their vendor's advisory regarding CVE-2026-98232 or locate the relevant fix commit within their source code. Remediation involves upgrading to a patched kernel or applying the upstream commit 3d676e458fe0, which addresses the issue in "scsi: core: Validate MODE SENSE lengths in scsi_cdl_enable()".
As interim mitigation measures if an immediate update is not feasible, implementing Command Duration Limits (CDL) support can reduce the risk. Linux 6.5 introduced CDL support; when the kernel scans a new SCSI device reporting itself as an ATA device with CDL capabilities, it invokes scsi_cdl_enable(). This function reads a mode page from the device into a 64-byte stack buffer and subsequently writes it back. The lengths provided by the device in its response were utilized without proper validation: len = min_t(size_t, sizeof(buf), data.length - data.header_length - data.block_descriptor_length); /* can wrap -> 64 */ buf_data = buf + data.header_length + data.block_descriptor_length; /* can point past buf */ Consequently, a device is capable of forcing the kernel to transmit up to 64 bytes of kernel stack data to it, while simultaneously clearing a single stack byte at a location determined by the device. All of this occurs during the automated scan, prior to any interaction with user space.
The Proof-of-Concept developed by the researchers operates on a Cynthion USB device connected to a PC running a standard Debian 6.12.22+bpo-amd64 kernel. The data leak allows the attacker to bypass KASLR, and the subsequent chain constructs counterfeit kernel structures to transform the single-byte overwrite into a controlled write. Upon disconnection of the device, the kernel executes a command that was previously supplied by the device, granting root privileges. Although the exploit's success is probabilistic, no system crashes are observed during unsuccessful attempts.
While Sashiko AI Review initially reported the bug on linux-scsi, Drivesec's research team discovered it independently, developed the necessary fix, and constructed the exploit chain. Drivesec is an Italian technology company that specializes in bolstering the cybersecurity of connected products and IoT/OT systems. Stemming from experience within the automotive and industrial domains, the firm assists manufacturers in embedding security throughout the entire product lifecycle by integrating technical proficiency, testing protocols, and adherence to regulations. Drivesec maintains a dedication to ongoing investment in specialized knowledge, which is further enhanced through significant partnerships with academic institutions and prominent research institutes.
This vulnerability underscores a critical vector in embedded systems security, demonstrating that physical access via standard peripheral interfaces can bypass traditional software-layer authentication mechanisms. The ability to manipulate kernel execution flow from a simple plug-in event highlights the necessity for robust input validation within kernel subsystems handling external hardware interactions.
Why it matters
This represents a critical physical attack vector against embedded systems with accessible USB ports, such as EV chargers or kiosks. Operators must verify their kernel versions against advisories like CVE-2026-98232 to mitigate this risk. Immediate patching or applying upstream fixes is necessary to prevent unauthorized root access.





