CVE-2024-42236
published high CVSS 3.1 · 7.8usb: gadget: configfs: Prevent OOB read/write in usb_string_copy()
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Linux | — | Linux88af8bbe4ef781031ad3370847553f3b42ba0076 to < a444c3fc264119801575ab086e03fb4952f23fd0 · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < c95fbdde87e39e5e0ae27f28bf6711edfb985caa · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < e8474a10c535e6a2024c3b06e37e4a3a23beb490 · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < 72b8ee0d9826e8ed00e0bdfce3e46b98419b37ce · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < 2d16f63d8030903e5031853e79d731ee5d474e70 · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < d1205033e912f9332c1dbefa812e6ceb0575ce0a · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < eecfefad0953b2f31aaefa058f7f348ff39c4bba · 88af8bbe4ef781031ad3370847553f3b42ba0076 to < 6d3c721e686ea6c59e18289b400cc95c76e927e0 · Other versions: unaffected | Affected | Not stated | Linux |
| Linux | — | Linux3.10 (affected) · 0 to < 3.10 (unaffected · semver) · 4.19.318 through 4.19.* (unaffected · semver) · 5.4.280 through 5.4.* (unaffected · semver) · 5.10.222 through 5.10.* (unaffected · semver) · 5.15.163 through 5.15.* (unaffected · semver) · 6.1.100 through 6.1.* (unaffected · semver) · 6.6.41 through 6.6.* (unaffected · semver) · 6.9.10 through 6.9.* (unaffected · semver) · 6.10 and later (unaffected · original_commit_for_fix) · Other versions: affected | Version-specific | Not stated | Linux |
| Amazon Linux | AL2 | Release evaluation | Not Affected | Not required | Amazon Linux assessment |
| Amazon Linux | AL2023 | Release evaluation | Not Affected | Not required | Amazon Linux assessment |
| Debian | bullseye | linux | Advisory build | 5.10.223-1 | DSA-5747-1 |
| Oracle Linux | 7 | kernel-uekaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Debian | bullseye | linux-6.1 | Advisory build | 6.1.119-1~deb11u1 | DLA-4008-1 |
| Oracle Linux | 7 | kernel-uekaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
Show 96 more entries
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Oracle Linux | 7 | kernel-uekx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uekx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-containerx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7 | ELSA-2024-12612 |
| Oracle Linux | 7 | kernel-uek-container-debugx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7 | ELSA-2024-12612 |
| Oracle Linux | 7 | kernel-uek-debugaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-debugaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-debugx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-debugx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-debug-develaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-debug-develaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-debug-develx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-debug-develx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-develaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-develaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-develx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-develx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-docaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-docx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-docx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-headersaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-toolsaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-toolsaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-toolsx86_64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-toolsx86_64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-tools-libsaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | kernel-uek-tools-libsaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | kernel-uek-tools-libs-develaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | perfaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | perfaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 7 | python-perfaarch64 | Advisory build | 0:4.14.35-2047.541.4.1.el7uek | ELSA-2024-12779 |
| Oracle Linux | 7 | python-perfaarch64 | Advisory build | 0:5.4.17-2136.335.4.el7uek | ELSA-2024-12610 |
| Oracle Linux | 8 | bpftoolaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | bpftoolx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uekaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uekaarch64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uekx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uekx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-containeraarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-containerx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-containerx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8 | ELSA-2024-12612 |
| Oracle Linux | 8 | kernel-uek-container-debugaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-container-debugx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-container-debugx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8 | ELSA-2024-12612 |
| Oracle Linux | 8 | kernel-uek-coreaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-corex86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debugaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debugaarch64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-debugx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debugx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-debug-coreaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-corex86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-develaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-develaarch64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-debug-develx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-develx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-debug-modulesaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-modulesx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-modules-extraaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-debug-modules-extrax86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-develaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-develaarch64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-develx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-develx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-docaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-docaarch64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-docx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-docx86_64 | Advisory build | 0:5.4.17-2136.335.4.el8uek | ELSA-2024-12610 |
| Oracle Linux | 8 | kernel-uek-modulesaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-modulesx86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-modules-extraaarch64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 8 | kernel-uek-modules-extrax86_64 | Advisory build | 0:5.15.0-210.163.7.el8uek | ELSA-2024-12618 |
| Oracle Linux | 9 | bpftoolaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | bpftoolx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uekaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uekx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-containeraarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-containerx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-container-debugaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-container-debugx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-coreaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-corex86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debugaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debugx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-coreaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-corex86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-develaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-develx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-modulesaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-modulesx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-modules-extraaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-debug-modules-extrax86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-develaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-develx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-docaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-docx86_64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
| Oracle Linux | 9 | kernel-uek-modulesaarch64 | Advisory build | 0:5.15.0-210.163.7.el9uek | ELSA-2024-12618 |
Package entries are limited to the first 100 builds and 100 linked advisories.
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.
Related advisories
Vendor advisories explicitly linked to this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 3.1
- Base score
- 7.8 / 10
- Severity
- high
- Provider
- Linux · cna
- Vector string
- CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Scenarios
- en: AV:L - The vulnerable input is a local `write(2)` to a USB gadget configfs attribute file (`/sys/kernel/config/usb_gadget/.../manufacturer`), not data from a USB peer or the network — no hardware, UDC binding, or physical access is needed. AC:L - A single deterministic `write(fd, "\0", 1)` always drives `strlen()` to 0 and performs the `str[-1]` out-of-bounds access; there is no race and no condition outside the attacker's control, and heap grooming for the OOB write is attacker-driven via repeated gadget/string alloc-free cycles. PR:L - Some local access to the gadget configfs attributes is required, and these files are routinely delegated to non-root identities (Android chowns `/config/usb_gadget` to system:system for the non-root USB gadget HAL; embedded images commonly group-delegate it), so an unprivileged/low-privileged local process can reach the path. UI:N - The attacker performs the configfs write themselves; no victim action, mount, or interaction of any kind is needed. S:U - The out-of-bounds read and write stay within kernel heap memory managed by the same security authority; no VM, IOMMU, or sandbox boundary is crossed. C:H - The bug is an out-of-bounds heap read plus heap corruption of an adjacent slab object, and such corruption is leveragable for information disclosure once the attacker grooms `kmalloc-128` to place a chosen victim object before the string buffer. I:H - `str[-1] = '\0'` is a genuine out-of-bounds heap write that clears the trailing byte of the neighbouring `kmalloc-128` object — an attacker-groomable NUL-byte poisoning primitive that corrupts kernel data structures. A:H - The OOB access can fault on an unmapped/guard page (KFENCE, DEBUG_PAGEALLOC) or trip KASAN, and clearing a byte of an adjacent live slab object readily leads to a later oops or panic.
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| Linux | Linux | 88af8bbe4ef781031ad3370847553f3b42ba0076 to < a444c3fc264119801575ab086e03fb4952f23fd0 (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < c95fbdde87e39e5e0ae27f28bf6711edfb985caa (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < e8474a10c535e6a2024c3b06e37e4a3a23beb490 (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < 72b8ee0d9826e8ed00e0bdfce3e46b98419b37ce (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < 2d16f63d8030903e5031853e79d731ee5d474e70 (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < d1205033e912f9332c1dbefa812e6ceb0575ce0a (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < eecfefad0953b2f31aaefa058f7f348ff39c4bba (affected · git)88af8bbe4ef781031ad3370847553f3b42ba0076 to < 6d3c721e686ea6c59e18289b400cc95c76e927e0 (affected · git)Default: unaffected | Linux · cna |
| Linux | Linux | 3.10 (affected)0 to < 3.10 (unaffected · semver)4.19.318 through 4.19.* (unaffected · semver)5.4.280 through 5.4.* (unaffected · semver)5.10.222 through 5.10.* (unaffected · semver)5.15.163 through 5.15.* (unaffected · semver)6.1.100 through 6.1.* (unaffected · semver)6.6.41 through 6.6.* (unaffected · semver)6.9.10 through 6.9.* (unaffected · semver)6.10 and later (unaffected · original_commit_for_fix)Default: affected | Linux · cna |
Weaknesses
0No weakness assertions.
References
9- https://git.kernel.org/stable/c/2d16f63d8030903e5031853e79d731ee5d474e70
- https://git.kernel.org/stable/c/6d3c721e686ea6c59e18289b400cc95c76e927e0
- https://git.kernel.org/stable/c/72b8ee0d9826e8ed00e0bdfce3e46b98419b37ce
- https://git.kernel.org/stable/c/a444c3fc264119801575ab086e03fb4952f23fd0
- https://git.kernel.org/stable/c/c95fbdde87e39e5e0ae27f28bf6711edfb985caa
- https://git.kernel.org/stable/c/d1205033e912f9332c1dbefa812e6ceb0575ce0a
- https://git.kernel.org/stable/c/e8474a10c535e6a2024c3b06e37e4a3a23beb490
- https://git.kernel.org/stable/c/eecfefad0953b2f31aaefa058f7f348ff39c4bba
- https://lists.debian.org/debian-lts-announce/2025/01/msg00001.html
Provider assertions
3Linux · cna
usb: gadget: configfs: Prevent OOB read/write in usb_string_copy()
CISA-ADP · adp
CISA ADP Vulnrichment
CVE · adp
CVE Program Container
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 8f19c3a101d8375412896b880ca0fb276aa0840266d49c8f4f54c580946bed45
- Ingested
- 23 Sep 2026, 08:26:31 UTC
- Source record
- Official CVE record