CVE-2024-42236

MEDIUM

Linux Kernel - Out-of-bounds Write in usb_string_copy()

Title source: llm
STIX 2.1

Description

In the Linux kernel, the following vulnerability has been resolved: usb: gadget: configfs: Prevent OOB read/write in usb_string_copy() Userspace provided string 's' could trivially have the length zero. Left unchecked this will firstly result in an OOB read in the form `if (str[0 - 1] == '\n') followed closely by an OOB write in the form `str[0 - 1] = '\0'`. There is already a validating check to catch strings that are too long. Let's supply an additional check for invalid strings that are too short.

Scores

CVSS v3 5.5
EPSS 0.0023
EPSS Percentile 14.0%
Attack Vector LOCAL
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

CISA SSVC

Vulnrichment
Exploitation none
Automatable no
Technical Impact partial

Details

CWE
CWE-787
Status published
Products (26)
linux/Kernel 3.10.0 - 4.19.318linux
linux/Kernel 4.20.0 - 5.4.280linux
linux/Kernel 5.11.0 - 5.15.163linux
linux/Kernel 5.16.0 - 6.1.100linux
linux/Kernel 5.5.0 - 5.10.222linux
linux/Kernel 6.2.0 - 6.6.41linux
linux/Kernel 6.7.0 - 6.9.10linux
Linux/Linux < 3.10
Linux/Linux 3.10
Linux/Linux 4.19.318 - 4.19.*
... and 16 more
Published Aug 07, 2024
Tracked Since Feb 18, 2026