CVE-2025-38717
JSON

7.8high

net: kcm: Fix race condition in kcm_unattach()

Severity
7.8high CVSS:3.1 by Linux
Exploit likelihood
0.13% (higher than 2% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
Linux

Description

In the Linux kernel, the following vulnerability has been resolved: net: kcm: Fix race condition in kcm_unattach() syzbot found a race condition when kcm_unattach(psock) and kcm_release(kcm) are executed at the same time. kcm_unattach() is missing a check of the flag kcm->tx_stopped before calling queue_work(). If the kcm has a reserved psock, kcm_unattach() might get executed between cancel_work_sync() and unreserve_psock() in kcm_release(), requeuing kcm->tx_work right before kcm gets freed in kcm_done(). Remove kcm->tx_stopped and replace it by the less error-prone disable_work_sync().

Affected

Product or packageVersionsReported by
Linux Linuxfrom ab7ac4eb9832e32a09f4e8042705484d2fb0aad3 before c0bffbc92a1ca3960fb9cdb8e9f75a68468eb308, from ab7ac4eb9832e32a09f4e8042705484d2fb0aad3 before 7275dc3bb8f91b23125ff3f47b6529935cf46152, from ab7ac4eb9832e32a09f4e8042705484d2fb0aad3 before 798733ee5d5788b12e8a52db1519abc17e826f69, from ab7ac4eb9832e32a09f4e8042705484d2fb0aad3 before 52565a935213cd6a8662ddb8efe5b4219343a25d, 4.6
Not affected: before 4.6, from 6.12.43 up to 6.12.*, from 6.15.11 up to 6.15.*, from 6.16.2 up to 6.16.*, from 6.17 up to *
CVE List
linux linux_kernelfrom 4.6 before 6.12.43, from 6.13 before 6.15.11, from 6.16 before 6.16.2, 6.17NVD

All scores

Linux7.8high CVSS:3.1CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
NVD4.7medium CVSS:3.1CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H

Classification

What each source says

CVE List

In the Linux kernel, the following vulnerability has been resolved: net: kcm: Fix race condition in kcm_unattach() syzbot found a race condition when kcm_unattach(psock) and kcm_release(kcm) are executed at the same time. kcm_unattach() is missing a check of the flag kcm->tx_stopped before calling queue_work(). If the kcm has a reserved psock, kcm_unattach() might get executed between cancel_work_sync() and unreserve_psock() in kcm_release(), requeuing kcm->tx_work right before kcm gets freed in kcm_done(). Remove kcm->tx_stopped and replace it by the less error-prone disable_work_sync().

NVD (es)

En el kernel de Linux, la siguiente vulnerabilidad ha sido resuelta: net: kcm: Corrige condición de carrera en kcm_unattach() syzbot encontró una condición de carrera cuando kcm_unattach(psock) y kcm_release(kcm) se ejecutan al mismo tiempo. A kcm_unattach() le falta una comprobación del flag kcm->tx_stopped antes de llamar a queue_work(). Si el kcm tiene un psock reservado, kcm_unattach() podría ejecutarse entre cancel_work_sync() y unreserve_psock() en kcm_release(), volviendo a encolar kcm->tx_work justo antes de que kcm sea liberado en kcm_done(). Eliminar kcm->tx_stopped y reemplazarlo por el menos propenso a errores disable_work_sync().

References

Sources

SourceRecordLicence
CVE ListCVE-2025-38717 changed 2026-08-05CVE Terms of Use
NVDCVE-2025-38717 changed 2026-10-19Public domain