7.1high
usb: gadget: configfs: Fix OOB read on empty string write
- Severity
- 7.1high CVSS:3.1 by NVD
- Exploit likelihood
- 0.19% (higher than 9% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Linux
Description
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: configfs: Fix OOB read on empty string write When writing an empty string to either 'qw_sign' or 'landingPage' sysfs attributes, the store functions attempt to access page[l - 1] before validating that the length 'l' is greater than zero. This patch fixes the vulnerability by adding a check at the beginning of os_desc_qw_sign_store() and webusb_landingPage_store() to handle the zero-length input case gracefully by returning immediately.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Linux Linux | from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 78b41148cfea2a3f04d87adf3a71b21735820a37, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before d68b7c8fefbaeae8f065b84e40cf64baf4cc0c76, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 15a87206879951712915c03c8952a73d6a74721e, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 2798111f8e504ac747cce911226135d50b8de468, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 58bdd5160184645771553ea732da5c2887fc9bd1, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 783ea37b237a9b524f1e5ca018ea17d772ee0ea0, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 22b7897c289cc25d99c603f5144096142a30d897, from 87213d388e927aaa88b21d5ff7e1f75ca2288da1 before 3014168731b7930300aab656085af784edc861f6 and 1 more Not affected: before 3.16, from 5.4.297 up to 5.4.*, from 5.10.241 up to 5.10.*, from 5.15.190 up to 5.15.*, from 6.1.147 up to 6.1.*, from 6.6.100 up to 6.6.* | CVE List |
| linux linux_kernel | from 3.16 before 5.4.297, from 5.5 before 5.10.241, from 5.11 before 5.15.190, from 5.16 before 6.1.147, from 6.2 before 6.6.100, from 6.7 before 6.12.40, from 6.13 before 6.15.8, 6.16 | NVD |
| debian debian_linux | 11.0 | NVD |
Classification
What each source says
CVE List
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: configfs: Fix OOB read on empty string write When writing an empty string to either 'qw_sign' or 'landingPage' sysfs attributes, the store functions attempt to access page[l - 1] before validating that the length 'l' is greater than zero. This patch fixes the vulnerability by adding a check at the beginning of os_desc_qw_sign_store() and webusb_landingPage_store() to handle the zero-length input case gracefully by returning immediately.
NVD (es)
En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: usb: gadget: configfs: Corrección de lectura OOB en escritura de cadena vacía. Al escribir una cadena vacía en los atributos sysfs 'qw_sign' o 'landingPage', las funciones de almacenamiento intentan acceder a page[l - 1] antes de validar que la longitud 'l' sea mayor que cero. Este parche corrige la vulnerabilidad añadiendo una comprobación al inicio de os_desc_qw_sign_store() y webusb_landingPage_store() para gestionar correctamente la entrada de longitud cero, retornando inmediatamente.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2025-38497 changed 2026-05-11 | CVE Terms of Use |
| NVD | CVE-2025-38497 changed 2026-06-17 | Public domain |