Cyber Resilience

CVE-2025-39870

Memory Safety in Linux Kernel 6.1.140 – 6.1.153

Published
23 September 2025
Modified
20 January 2026
Patch / advisory
CVSS Score v3.1 7.8
Click a component to see what it means
Raw vectorCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS Score 0.0014 4th percentile
Risk Priority 55 floored blend · peak EPSS

Summary

CVE-2025-39870 is a high-severity Double Free (CWE-415) vulnerability in Linux Linux Kernel. Its CVSS base score is 7.8 (High).

Operationally, ranked at the 4th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog.

The strongest mitigations our analysis identified map to SI-2 (Flaw Remediation) and SA-11 (Developer Testing and Evaluation) — see the control section below for these in your framework.

EU & UK References

Vulnerability Data

In the Linux kernel, the following vulnerability has been resolved: dmaengine: idxd: Fix double free in idxd_setup_wqs() The clean up in idxd_setup_wqs() has had a couple bugs because the error handling is a bit subtle. It's simpler to just re-write…

more

it in a cleaner way. The issues here are: 1) If "idxd->max_wqs" is <= 0 then we call put_device(conf_dev) when "conf_dev" hasn't been initialized. 2) If kzalloc_node() fails then again "conf_dev" is invalid. It's either uninitialized or it points to the "conf_dev" from the previous iteration so it leads to a double free. It's better to free partial loop iterations within the loop and then the unwinding at the end can handle whole loop iterations. I also renamed the labels to describe what the goto does and not where the goto was located.

CWE(s)

Related Threats

CVEs Like This One

CVE-2023-52691Same product: Debian Debian Linux
CVE-2024-49882Same product: Debian Debian Linux
CVE-2024-36940Same product: Debian Debian Linux
CVE-2025-38313Same product: Debian Debian Linux
CVE-2025-39914Same product: Debian Debian Linux
CVE-2024-26846Same product: Debian Debian Linux
CVE-2025-38699Same product: Debian Debian Linux
CVE-2024-41073Same product: Debian Debian Linux
CVE-2024-49989Same product: Debian Debian Linux
CVE-2024-35847Same product: Debian Debian Linux

Affected Assets

linux
linux kernel
6.15, 6.17 · 6.1.140 — 6.1.153 · 6.6.92 — 6.6.107 · 6.12.30 — 6.12.48
debian
debian linux
11.0

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)
  • SA-11 Developer Testing and Evaluation
  • SA-15 Development Process, Standards, and Tools
  • SI-2 Flaw Remediation
Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 1 hardening rule · 1 OS baseline
Validate
Prove the fix (OWASP ASVS)

Mitigating Controls (NIST 800-53 r5) AI

prevent

Rigorous developer testing of error paths in functions like idxd_setup_wqs() would detect the uninitialized conf_dev and kzalloc failure cases that cause double-free.

prevent

Use of secure development tools and standards (static analysis, memory sanitizers, structured error handling) directly prevents subtle double-free bugs from incorrect goto/unwind logic in kernel drivers.

prevent

Applying the kernel patch that rewrites idxd_setup_wqs() cleanup eliminates the CWE-415 double-free condition described in the CVE.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.PS-06 full match
prevents

Secure SDLC practices directly prevent double-free errors via static analysis, safe memory APIs, and testing.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

detects

Security testing in development can detect double-free conditions before release.

prevents

Secure development life cycle includes memory-safety practices that can prevent double-free bugs.

prevents

Application security requirements can mandate memory-safety rules that reduce double-free risk.

prevents

Secure system architecture and engineering principles can prescribe safe memory-management patterns.

prevents

Secure coding standards directly address proper use of free() and similar functions.

References