CVE-2025-39727: mm: swap: fix potential buffer overflow in setup_clusters()
In the Linux kernel, the following vulnerability has been resolved:
mm: swap: fix potential buffer overflow in setupclusters()
In setupswapmap(), we only ensure badpages are in range (0, lastpage]. As maxpages might be < lastpage, setupclusters() will encounter a buffer overflow when a badpage is >= maxpages.
Only call incclusterinfopage() for badpage which is < maxpages to fix the issue.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
ubuntu/linux-aws-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1017.17~24.04.1 - Upgrade
Upgrade
ubuntu/linux-azure-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1017.17~24.04.1 - Upgrade
Upgrade
ubuntu/linux-gcp-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1020.21~24.04.1 - Upgrade
Upgrade
ubuntu/linux-oem-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1016.16 - Upgrade
Upgrade
ubuntu/linux-oracle-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1017.17~24.04.1 - Upgrade
Upgrade
ubuntu/linux-riscv-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-36.36.1~24.04.1 - Upgrade
Upgrade
ubuntu/linux-realtime-6.14to a version that resolves this vulnerability.Fixed in 6.14.0-1016.16~24.04.1
Event History
Frequently Asked Questions
What is the severity of CVE-2025-39727?
CVE-2025-39727 has a high severity rating due to the potential for buffer overflow vulnerabilities.
How do I fix CVE-2025-39727?
To fix CVE-2025-39727, update your Linux kernel to the latest patched version that addresses this vulnerability.
What systems are affected by CVE-2025-39727?
CVE-2025-39727 affects various versions of the Linux kernel where the buffer overflow vulnerability could be exploited.
What is the impact of CVE-2025-39727?
The impact of CVE-2025-39727 includes potential crashes and exploits due to buffer overflow in memory management.
When was CVE-2025-39727 resolved?
CVE-2025-39727 was resolved in a recent patch release for the Linux kernel.