CVE-2025-38277 (GCVE-0-2025-38277)
Vulnerability from cvelistv5
Published
2025-07-10 07:41
Modified
2025-07-28 04:17
Severity ?
VLAI Severity ?
EPSS score ?
Summary
In the Linux kernel, the following vulnerability has been resolved:
mtd: nand: ecc-mxic: Fix use of uninitialized variable ret
If ctx->steps is zero, the loop processing ECC steps is skipped,
and the variable ret remains uninitialized. It is later checked
and returned, which leads to undefined behavior and may cause
unpredictable results in user space or kernel crashes.
This scenario can be triggered in edge cases such as misconfigured
geometry, ECC engine misuse, or if ctx->steps is not validated
after initialization.
Initialize ret to zero before the loop to ensure correct and safe
behavior regardless of the ctx->steps value.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
References
Impacted products
{ "containers": { "cna": { "affected": [ { "defaultStatus": "unaffected", "product": "Linux", "programFiles": [ "drivers/mtd/nand/ecc-mxic.c" ], "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "vendor": "Linux", "versions": [ { "lessThan": "4d9d6e4be09472aa72953caca3dbefdc27846170", "status": "affected", "version": "48e6633a9fa2400b53a964358753769f291a7eb0", "versionType": "git" }, { "lessThan": "a0d9d9b5a4634e146ae41cb25667322e5c7d74d2", "status": "affected", "version": "48e6633a9fa2400b53a964358753769f291a7eb0", "versionType": "git" }, { "lessThan": "7a23cc510ecaabab4f6df7e9d910d16e279b72ad", "status": "affected", "version": "48e6633a9fa2400b53a964358753769f291a7eb0", "versionType": "git" }, { "lessThan": "49482f4a39620f6afedcd3f6aa9e0d558b6a460b", "status": "affected", "version": "48e6633a9fa2400b53a964358753769f291a7eb0", "versionType": "git" }, { "lessThan": "d95846350aac72303036a70c4cdc69ae314aa26d", "status": "affected", "version": "48e6633a9fa2400b53a964358753769f291a7eb0", "versionType": "git" } ] }, { "defaultStatus": "affected", "product": "Linux", "programFiles": [ "drivers/mtd/nand/ecc-mxic.c" ], "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "vendor": "Linux", "versions": [ { "status": "affected", "version": "5.18" }, { "lessThan": "5.18", "status": "unaffected", "version": "0", "versionType": "semver" }, { "lessThanOrEqual": "6.1.*", "status": "unaffected", "version": "6.1.142", "versionType": "semver" }, { "lessThanOrEqual": "6.6.*", "status": "unaffected", "version": "6.6.94", "versionType": "semver" }, { "lessThanOrEqual": "6.12.*", "status": "unaffected", "version": "6.12.34", "versionType": "semver" }, { "lessThanOrEqual": "6.15.*", "status": "unaffected", "version": "6.15.3", "versionType": "semver" }, { "lessThanOrEqual": "*", "status": "unaffected", "version": "6.16", "versionType": "original_commit_for_fix" } ] } ], "cpeApplicability": [ { "nodes": [ { "cpeMatch": [ { "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionEndExcluding": "6.1.142", "versionStartIncluding": "5.18", "vulnerable": true }, { "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionEndExcluding": "6.6.94", "versionStartIncluding": "5.18", "vulnerable": true }, { "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionEndExcluding": "6.12.34", "versionStartIncluding": "5.18", "vulnerable": true }, { "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionEndExcluding": "6.15.3", "versionStartIncluding": "5.18", "vulnerable": true }, { "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionEndExcluding": "6.16", "versionStartIncluding": "5.18", "vulnerable": true } ], "negate": false, "operator": "OR" } ] } ], "descriptions": [ { "lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nmtd: nand: ecc-mxic: Fix use of uninitialized variable ret\n\nIf ctx-\u003esteps is zero, the loop processing ECC steps is skipped,\nand the variable ret remains uninitialized. It is later checked\nand returned, which leads to undefined behavior and may cause\nunpredictable results in user space or kernel crashes.\n\nThis scenario can be triggered in edge cases such as misconfigured\ngeometry, ECC engine misuse, or if ctx-\u003esteps is not validated\nafter initialization.\n\nInitialize ret to zero before the loop to ensure correct and safe\nbehavior regardless of the ctx-\u003esteps value.\n\nFound by Linux Verification Center (linuxtesting.org) with SVACE." } ], "providerMetadata": { "dateUpdated": "2025-07-28T04:17:06.562Z", "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "shortName": "Linux" }, "references": [ { "url": "https://git.kernel.org/stable/c/4d9d6e4be09472aa72953caca3dbefdc27846170" }, { "url": "https://git.kernel.org/stable/c/a0d9d9b5a4634e146ae41cb25667322e5c7d74d2" }, { "url": "https://git.kernel.org/stable/c/7a23cc510ecaabab4f6df7e9d910d16e279b72ad" }, { "url": "https://git.kernel.org/stable/c/49482f4a39620f6afedcd3f6aa9e0d558b6a460b" }, { "url": "https://git.kernel.org/stable/c/d95846350aac72303036a70c4cdc69ae314aa26d" } ], "title": "mtd: nand: ecc-mxic: Fix use of uninitialized variable ret", "x_generator": { "engine": "bippy-1.2.0" } } }, "cveMetadata": { "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "assignerShortName": "Linux", "cveId": "CVE-2025-38277", "datePublished": "2025-07-10T07:41:56.916Z", "dateReserved": "2025-04-16T04:51:23.998Z", "dateUpdated": "2025-07-28T04:17:06.562Z", "state": "PUBLISHED" }, "dataType": "CVE_RECORD", "dataVersion": "5.1", "vulnerability-lookup:meta": { "nvd": "{\"cve\":{\"id\":\"CVE-2025-38277\",\"sourceIdentifier\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\",\"published\":\"2025-07-10T08:15:26.003\",\"lastModified\":\"2025-07-10T13:17:30.017\",\"vulnStatus\":\"Awaiting Analysis\",\"cveTags\":[],\"descriptions\":[{\"lang\":\"en\",\"value\":\"In the Linux kernel, the following vulnerability has been resolved:\\n\\nmtd: nand: ecc-mxic: Fix use of uninitialized variable ret\\n\\nIf ctx-\u003esteps is zero, the loop processing ECC steps is skipped,\\nand the variable ret remains uninitialized. It is later checked\\nand returned, which leads to undefined behavior and may cause\\nunpredictable results in user space or kernel crashes.\\n\\nThis scenario can be triggered in edge cases such as misconfigured\\ngeometry, ECC engine misuse, or if ctx-\u003esteps is not validated\\nafter initialization.\\n\\nInitialize ret to zero before the loop to ensure correct and safe\\nbehavior regardless of the ctx-\u003esteps value.\\n\\nFound by Linux Verification Center (linuxtesting.org) with SVACE.\"},{\"lang\":\"es\",\"value\":\"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: mtd: nand: ecc-mxic: Se corrige el uso de la variable ret sin inicializar. Si ctx-\u0026gt;steps es cero, se omite el procesamiento del bucle de pasos ECC y la variable ret permanece sin inicializar. Posteriormente, se verifica y se devuelve, lo que genera un comportamiento indefinido y puede causar resultados impredecibles en el espacio de usuario o fallos del kernel. Este escenario puede activarse en casos extremos, como una geometr\u00eda mal configurada, un uso indebido del motor ECC o si ctx-\u0026gt;steps no se valida tras la inicializaci\u00f3n. Inicialice ret a cero antes del bucle para garantizar un comportamiento correcto y seguro, independientemente del valor de ctx-\u0026gt;steps. Encontrado por el Centro de Verificaci\u00f3n de Linux (linuxtesting.org) con SVACE.\"}],\"metrics\":{},\"references\":[{\"url\":\"https://git.kernel.org/stable/c/49482f4a39620f6afedcd3f6aa9e0d558b6a460b\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/4d9d6e4be09472aa72953caca3dbefdc27846170\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/7a23cc510ecaabab4f6df7e9d910d16e279b72ad\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/a0d9d9b5a4634e146ae41cb25667322e5c7d74d2\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"},{\"url\":\"https://git.kernel.org/stable/c/d95846350aac72303036a70c4cdc69ae314aa26d\",\"source\":\"416baaa9-dc9f-4396-8d5f-8c081fb06d67\"}]}}" } }
Loading…
Loading…
Sightings
Author | Source | Type | Date |
---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
- Confirmed: The vulnerability is confirmed from an analyst perspective.
- Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
- Patched: This vulnerability was successfully patched by the user reporting the sighting.
- Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
- Not confirmed: The user expresses doubt about the veracity of the vulnerability.
- Not patched: This vulnerability was not successfully patched by the user reporting the sighting.
Loading…
Loading…