{"id":"CVE-2025-38282","aliases":["CVE-2025-38282"],"related":[],"kind":"vulnerability","state":"published","title":"kernfs: Relax constraint in draining guard","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nkernfs: Relax constraint in draining guard\n\nThe active reference lifecycle provides the break/unbreak mechanism but\nthe active reference is not truly active after unbreak -- callers don't\nuse it afterwards but it's important for proper pairing of kn->active\ncounting. Assuming this mechanism is in place, the WARN check in\nkernfs_should_drain_open_files() is too sensitive -- it may transiently\ncatch those (rightful) callers between\nkernfs_unbreak_active_protection() and kernfs_put_active() as found out by Chen\nRidong:\n\n\tkernfs_remove_by_name_ns\tkernfs_get_active // active=1\n\t__kernfs_remove\t\t\t\t\t  // active=0x80000002\n\tkernfs_drain\t\t\t...\n\twait_event\n\t//waiting (active == 0x80000001)\n\t\t\t\t\tkernfs_break_active_protection\n\t\t\t\t\t// active = 0x80000001\n\t// continue\n\t\t\t\t\tkernfs_unbreak_active_protection\n\t\t\t\t\t// active = 0x80000002\n\t...\n\tkernfs_should_drain_open_files\n\t// warning occurs\n\t\t\t\t\tkernfs_put_active\n\nTo avoid the false positives (mind panic_on_warn) remove the check altogether.\n(This is meant as quick fix, I think active reference break/unbreak may be\nsimplified with larger rework.)","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nkernfs: Relax constraint in draining guard\n\nThe active reference lifecycle provides the break/unbreak mechanism but\nthe active reference is not truly active after unbreak -- callers don't\nuse it afterwards but it's important for proper pairing of kn->active\ncounting. Assuming this mechanism is in place, the WARN check in\nkernfs_should_drain_open_files() is too sensitive -- it may transiently\ncatch those (rightful) callers between\nkernfs_unbreak_active_protection() and kernfs_put_active() as found out by Chen\nRidong:\n\n\tkernfs_remove_by_name_ns\tkernfs_get_active // active=1\n\t__kernfs_remove\t\t\t\t\t  // active=0x80000002\n\tkernfs_drain\t\t\t...\n\twait_event\n\t//waiting (active == 0x80000001)\n\t\t\t\t\tkernfs_break_active_protection\n\t\t\t\t\t// active = 0x80000001\n\t// continue\n\t\t\t\t\tkernfs_unbreak_active_protection\n\t\t\t\t\t// active = 0x80000002\n\t...\n\tkernfs_should_drain_open_files\n\t// warning occurs\n\t\t\t\t\tkernfs_put_active\n\nTo avoid the false positives (mind panic_on_warn) remove the check altogether.\n(This is meant as quick fix, I think active reference break/unbreak may be\nsimplified with larger rework.)","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: kernfs: relajar restricción en el drenaje de la protección El ciclo de vida de la referencia activa proporciona el mecanismo de interrupción/desconexión, pero la referencia activa no está verdaderamente activa después de la conexión; los llamadores no la usan después, pero es importante para el emparejamiento adecuado del conteo kn-&gt;activo. Suponiendo que este mecanismo está en su lugar, la comprobación WARN en kernfs_should_drain_open_files() es demasiado sensible - puede atrapar transitoriamente a aquellos llamadores (legítimos) entre kernfs_unbreak_active_protection() y kernfs_put_active() como descubrió Chen Ridong: kernfs_remove_by_name_ns kernfs_get_active // active=1 __kernfs_remove // active=0x80000002 kernfs_drain ... wait_event //waiting (active == 0x80000001) kernfs_break_active_protection // active = 0x80000001 // continuar kernfs_unbreak_active_protection // active = 0x80000002 ... kernfs_should_drain_open_files // ocurre una advertencia kernfs_put_active Para evitar los falsos positivos (tenga en cuenta \"panic_on_warn\"), elimine la comprobación por completo. (Esto es una solución rápida; creo que la interrupción/desconexión de referencias activas se puede simplificar con una revisión más exhaustiva).","source":"nvd"}],"published":"2025-07-10T07:42:00.395Z","modified":"2026-11-05T21:18:24.423Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"bdb2fd7fc56e197a63c0b0e7e07d25d5e20e7c72","fixed":"2d6a67c2b3b87808a347dc1047b520a9dd177a4f","status":"affected"},{"type":"git","introduced":"bdb2fd7fc56e197a63c0b0e7e07d25d5e20e7c72","fixed":"6c81f1c7812c61f187bed1b938f1d2e391d503ab","status":"affected"},{"type":"git","introduced":"bdb2fd7fc56e197a63c0b0e7e07d25d5e20e7c72","fixed":"6bfb154f95d5f0ab7ed056f23aba8c1a94cb3927","status":"affected"},{"type":"git","introduced":"bdb2fd7fc56e197a63c0b0e7e07d25d5e20e7c72","fixed":"72275c888f8962b406ee9c6885c79bf68cca5a63","status":"affected"},{"type":"git","introduced":"bdb2fd7fc56e197a63c0b0e7e07d25d5e20e7c72","fixed":"071d8e4c2a3b0999a9b822e2eb8854784a350f8a","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"6.1","status":"affected"},{"type":"semver","introduced":"0","fixed":"6.1","status":"unaffected"},{"type":"semver","introduced":"6.1.142","lastAffected":"6.1.*","status":"unaffected"},{"type":"semver","introduced":"6.6.94","lastAffected":"6.6.*","status":"unaffected"},{"type":"semver","introduced":"6.12.34","lastAffected":"6.12.*","status":"unaffected"},{"type":"semver","introduced":"6.15.3","lastAffected":"6.15.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.16","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"6.1","fixed":"6.1.142"},{"status":"affected","introduced":"6.2","fixed":"6.6.94"},{"status":"affected","introduced":"6.7","fixed":"6.12.34"},{"status":"affected","introduced":"6.13","fixed":"6.15.3"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"11.0"}],"vendor":"debian","product":"debian_linux","cpe":"cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/2d6a67c2b3b87808a347dc1047b520a9dd177a4f","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/6c81f1c7812c61f187bed1b938f1d2e391d503ab","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/6bfb154f95d5f0ab7ed056f23aba8c1a94cb3927","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/72275c888f8962b406ee9c6885c79bf68cca5a63","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/071d8e4c2a3b0999a9b822e2eb8854784a350f8a","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/10/msg00008.html","tags":["mailing-list","third-party-advisory"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-11-05T20:53:01.163Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2025-38282","url":"https://www.cve.org/CVERecord?id=CVE-2025-38282","licence":"CVE Terms of Use","modified":"2026-11-05T21:02:30.419Z"},{"source":"nvd","name":"NVD","id":"CVE-2025-38282","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-38282","licence":"Public domain","modified":"2026-11-05T21:18:24.423Z"}],"updatedAt":"2026-11-25T22:59:01.053Z","epss":{"score":0.00196,"percentile":0.09776,"date":"2026-12-01T12:00:22.000Z"}}