KernelScan.io

HIGH

usb UCSI Connector OOB

CVE-2026-31729

CVSS 7.8 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

KernelScan AI6.8MEDIUM

01

In the Linux kernel, the following vulnerability has been resolved: usb: typec: ucsi: validate connector number in ucsi_notify_common() The connector number extracted from CCI via UCSI_CCI_CONNECTOR() is a 7-bit field (0-127) that is used to index into the connector array in ucsi_connector_change(). However, the array is only allocated for the number of connectors reported by the device (typically 2-4 entries). A malicious or malfunctioning device could report an out-of-range connector number in the CCI, causing an out-of-bounds array access in ucsi_connector_change(). Add a bounds check in ucsi_notify_common(), the central point where CCI is parsed after arriving from hardware, so that bogus connector numbers are rejected before they propagate further.

02

Engine v0.2.0

Risk summary

A malicious or malfunctioning USB Type-C device can trigger an out-of-bounds array access by reporting invalid connector numbers in the Command Completion and Indication (CCI) field. This affects systems with USB Type-C ports where untrusted devices can be connected, potentially leading to information disclosure or system crashes.

Affecteddrivers/usb/typec/ucsi/ucsi.c (USB Type-C UCSI)

Vulnerability analysis

The vulnerability occurs in the UCSI (USB Type-C Connector System Software Interface) driver where connector numbers from hardware are used as array indices without bounds checking. The UCSI_CCI_CONNECTOR() macro extracts a 7-bit connector number (0-127) from the CCI field, but the connector array is only allocated for the actual number of connectors reported by the device (typically 2-4). A malicious device can send a CCI with an out-of-range connector number, causing ucsi_connector_change() to access memory beyond the allocated array bounds. The fix adds validation in ucsi_notify_common() to ensure the connector number does not exceed ucsi->cap.num_connectors before passing it to ucsi_connector_change().

03

BranchFixed inPatch commit
6.126.12.81f6dcbf2b024d
6.186.18.22f4e608fe12b7
6.196.19.1298429e9ec89a
mainline7.0d2d8c17ac01a