Description
In the Linux kernel, the following vulnerability has been resolved:
mm: resolve faulty mmap_region() error path behaviour
The mmap_region() function is somewhat terrifying, with spaghetti-like
control flow and numerous means by which issues can arise and incomplete
state, memory leaks and other unpleasantness can occur.
A large amount of the complexity arises from trying to handle errors late
in the process of mapping a VMA, which forms the basis of recently
observed issues with resource leaks and observable inconsistent state.
Taking advantage of previous patches in this series we move a number of
checks earlier in the code, simplifying things by moving the core of the
logic into a static internal function __mmap_region().
Doing this allows us to perform a number of checks up front before we do
any real work, and allows us to unwind the writable unmap check
unconditionally as required and to perform a CONFIG_DEBUG_VM_MAPLE_TREE
validation unconditionally also.
We move a number of things here:
1. We preallocate memory for the iterator before we call the file-backed
memory hook, allowing us to exit early and avoid having to perform
complicated and error-prone close/free logic. We carefully free
iterator state on both success and error paths.
2. The enclosing mmap_region() function handles the mapping_map_writable()
logic early. Previously the logic had the mapping_map_writable() at the
point of mapping a newly allocated file-backed VMA, and a matching
mapping_unmap_writable() on success and error paths.
We now do this unconditionally if this is a file-backed, shared writable
mapping. If a driver changes the flags to eliminate VM_MAYWRITE, however
doing so does not invalidate the seal check we just performed, and we in
any case always decrement the counter in the wrapper.
We perform a debug assert to ensure a driver does not attempt to do the
opposite.
3. We also move arch_validate_flags() up into the mmap_region()
function. This is only relevant on arm64 and sparc64, and the check is
only meaningful for SPARC with ADI enabled. We explicitly add a warning
for this arch if a driver invalidates this check, though the code ought
eventually to be fixed to eliminate the need for this.
With all of these measures in place, we no longer need to explicitly close
the VMA on error paths, as we place all checks which might fail prior to a
call to any driver mmap hook.
This eliminates an entire class of errors, makes the code easier to reason
about and more robust.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| Linux | Linux | 5.10.150 – < 5.10.231, 5.15.75 – < 5.15.174, 5.19.17 – < 5.20, 6.0.3 – < 6.1, 6.1 | 5.10.231 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | linux | 6.12.3-1 | — |
| Debian 13 | linux | 6.12.3-1 | — |
| Debian 12 | linux | 6.1.119-1 | — |
| Debian 11 | linux | 5.10.234-1 | DLA-4075-1 |
| Debian 11 | linux-6.1 | 6.1.119-1~deb11u1 | DLA-4008-1 |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Nvidia-BlueField 22.04 LTS | linux-bluefield | 5.15.0-1062.64 | — |
| Ubuntu 24.04 LTS | linux | 6.8.0-58.60 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-aws | 6.8.0-1027.29 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-azure | 6.8.0-1027.32 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-azure-nvidia | 6.8.0-1014.15 | USN-7468-1 |
| Ubuntu 24.04 LTS | linux-gcp | 6.8.0-1028.30 | USN-7450-1 |
| Ubuntu 24.04 LTS | linux-gcp-6.11 +7 | No fix yet | — |
| Ubuntu 24.04 LTS | linux-gke | 6.8.0-1023.27 | USN-7450-1 |
| Ubuntu 24.04 LTS | linux-gkeop | 6.8.0-1010.12 | USN-7450-1 |
| Ubuntu 24.04 LTS | linux-ibm | 6.8.0-1024.24 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-nvidia | 6.8.0-1026.29 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-nvidia-lowlatency | 6.8.0-1026.29.1 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-nvidia-tegra | 6.8.0-1008.8 | — |
| Ubuntu 24.04 LTS | linux-oem-6.8 | 6.8.0-1026.26 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-oracle | 6.8.0-1024.25 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-raspi | 6.8.0-1028.32 | USN-7524-1 |
| Ubuntu 24.04 LTS | linux-riscv +1 | 6.8.0-58.60.1 | USN-7449-1 |
| Ubuntu 24.04 LTS | linux-xilinx | 6.8.0-1017.18 | — |
| Ubuntu 22.04 LTS | linux +1 | 5.15.0-135.146 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-aws | 5.15.0-1080.87 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-aws-6.8 | 6.8.0-1027.29~22.04.1 | USN-7451-1 |
| Ubuntu 22.04 LTS | linux-azure | 5.15.0-1084.93 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-azure-6.8 | 6.8.0-1027.32~22.04.1 | USN-7449-1 |
| Ubuntu 22.04 LTS | linux-azure-fde | 5.15.0-1084.93.1 | — |
| Ubuntu 22.04 LTS | linux-gcp | 5.15.0-1079.88 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-gcp-6.8 | 6.8.0-1028.30~22.04.1 | USN-7452-1 |
| Ubuntu 22.04 LTS | linux-gke +1 | 5.15.0-1077.83 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-gkeop | 5.15.0-1062.70 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-hwe-6.8 | 6.8.0-58.60~22.04.1 | USN-7449-2 |
| Ubuntu 22.04 LTS | linux-ibm | 5.15.0-1072.75 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-ibm-6.8 | 6.8.0-1024.24~22.04.1 | — |
| Ubuntu 22.04 LTS | linux-intel-iot-realtime | 5.15.0-1073.75 | — |
| Ubuntu 22.04 LTS | linux-intel-iotg | 5.15.0-1075.81 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-kvm | 5.15.0-1076.81 | USN-7388-1 |
| Ubuntu 22.04 LTS | linux-nvidia | 5.15.0-1074.75 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-nvidia-6.8 | 6.8.0-1026.29~22.04.1 | USN-7449-1 |
| Ubuntu 22.04 LTS | linux-nvidia-tegra | 5.15.0-1033.33 | USN-7389-1 |
| Ubuntu 22.04 LTS | linux-nvidia-tegra-igx | 5.15.0-1021.21 | USN-7389-1 |
| Ubuntu 22.04 LTS | linux-oracle-6.8 | 6.8.0-1024.25~22.04.1 | USN-7449-1 |
| Ubuntu 22.04 LTS | linux-raspi | 5.15.0-1074.77 | USN-7387-1 |
| Ubuntu 22.04 LTS | linux-riscv +31 | No fix yet | — |
| Ubuntu 22.04 LTS | linux-riscv-6.8 +1 | 6.8.0-58.60.1~22.04.1 | USN-7449-1 |
| Ubuntu 22.04 LTS | linux-xilinx-zynqmp | 5.15.0-1044.48 | USN-7390-1 |
| Ubuntu 20.04 LTS | linux-aws-5.15 | 5.15.0-1080.87~20.04.1 | USN-7388-1 |
| Ubuntu 20.04 LTS | linux-azure-5.15 | 5.15.0-1086.95~20.04.1 | USN-7421-1 |
| Ubuntu 20.04 LTS | linux-azure-fde-5.15 | 5.15.0-1086.95~20.04.1.1 | USN-7421-1 |
| Ubuntu 20.04 LTS | linux-gcp-5.15 | 5.15.0-1081.90~20.04.1 | USN-7459-2 |
| Ubuntu 20.04 LTS | linux-gke +28 | No fix yet | — |
| Ubuntu 20.04 LTS | linux-hwe-5.15 | 5.15.0-136.147~20.04.1 | USN-7407-1 |
| Ubuntu 20.04 LTS | linux-ibm-5.15 | 5.15.0-1074.77~20.04.1 | USN-7458-1 |
| Ubuntu 20.04 LTS | linux-lowlatency-hwe-5.15 | 5.15.0-135.146~20.04.1 | USN-7387-1 |
| Ubuntu 20.04 LTS | linux-oracle-5.15 +1 | 5.15.0-1077.83~20.04.1 | USN-7459-1, USN-7387-1 |
| Ubuntu 20.04 LTS | linux-riscv-5.15 | 5.15.0-1075.79~20.04.1 | — |
| Ubuntu 18.04 LTS | linux-gcp +13 | No fix yet | — |
Show 7 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 16.04 LTS | linux-hwe-edge | No fix yet | — |
| Ubuntu Pro Realtime 24.04 LTS | linux-raspi-realtime | 6.8.0-2023.24 | USN-7523-1 |
| Ubuntu Pro Realtime 24.04 LTS | linux-realtime | 6.8.1-1020.21 | USN-7453-1 |
| Ubuntu Pro Realtime 22.04 LTS | linux-intel-iot-realtime | 5.15.0-1073.75 | USN-7387-3 |
| Ubuntu Pro Realtime 22.04 LTS | linux-realtime | 5.15.0-1080.88 | USN-7387-3 |
| Ubuntu Pro Realtime 22.04 LTS | linux-realtime-6.8 | 6.8.1-1020.21~22.04.1 | — |
| Ubuntu Pro FIPS-updates 24.04 LTS | linux-fips | 6.8.0-78.78+fips1 | — |
| Ubuntu Pro FIPS-updates 22.04 LTS | linux-aws-fips | 5.15.0-1080.87+fips1 | USN-7387-2 |
| Ubuntu Pro FIPS-updates 22.04 LTS | linux-azure-fips | 5.15.0-1083.92+fips1 | USN-7387-2 |
| Ubuntu Pro FIPS-updates 22.04 LTS | linux-fips | 5.15.0-135.146+fips1 | USN-7387-2 |
| Ubuntu Pro FIPS-updates 22.04 LTS | linux-gcp-fips | 5.15.0-1079.88+fips1 | USN-7387-2 |
| Ubuntu Pro FIPS-preview 22.04 LTS | linux-fips +3 | No fix yet | — |
| Ubuntu Pro 20.04 LTS | linux-nvidia-tegra-5.15 | 5.15.0-1039.39~20.04.1 | — |
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 9 | rv +77 | 5.14.0-570.12.1.el9_6 | RHSA-2025:6966 |
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP6 | kernel-64kb +6 | 6.4.0-150600.23.30.1 | SUSE-SU-2024:4318-1 |
| SLES 15 SP6 | kernel-azure +2 | 6.4.0-150600.8.20.1 | SUSE-SU-2024:4316-1 |
| SLES 15 SP6 | kernel-coco +3 | 6.4.0-15061.9.coco15sp6.1 | SUSE-SU-2024:4387-1 |
| SLES 15 SP6 | kernel-default-base | 6.4.0-150600.23.30.1.150600.12.12.6 | SUSE-SU-2024:4318-1 |
Show 4 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLE Micro 6.1 | kernel-default-base | 6.4.0-24.1.21.4 | SUSE-SU-2025:20247-1 |
| SLE Micro 6.1 | kernel-livepatch-MICRO-6-0-RT_Update_4 | 1-1.1 | SUSE-SU-2025:20246-1 |
| SLE Micro 6.1 | kernel-livepatch-MICRO-6-0_Update_4 | 1-1.2 | SUSE-SU-2025:20247-1 |
| SLE Micro 6.1 | kernel-rt +1 | 6.4.0-22.1 | SUSE-SU-2025:20246-1 |
| SLE Micro 6.1 | kernel-source +2 | 6.4.0-24.1 | SUSE-SU-2025:20247-1 |
| SLE Micro 6.0 | kernel-default-base | 6.4.0-24.1.21.4 | SUSE-SU-2025:20164-1 |
| SLE Micro 6.0 | kernel-livepatch-MICRO-6-0-RT_Update_4 | 1-1.1 | SUSE-SU-2025:20163-1 |
| SLE Micro 6.0 | kernel-livepatch-MICRO-6-0_Update_4 | 1-1.2 | SUSE-SU-2025:20164-1 |
| SLE Micro 6.0 | kernel-rt +1 | 6.4.0-22.1 | SUSE-SU-2025:20163-1 |
| SLE Micro 6.0 | kernel-source +2 | 6.4.0-24.1 | SUSE-SU-2025:20164-1 |
| SLE Live Patching 15 SP6 | kernel-default | 6.4.0-150600.23.30.1 | SUSE-SU-2024:4318-1 |
| SLE Live Patching 15 SP6 | kernel-livepatch-SLE15-SP6-RT_Update_6 | 1-150600.1.3.1 | SUSE-SU-2024:4314-1 |
| SLE Live Patching 15 SP6 | kernel-livepatch-SLE15-SP6_Update_6 | 1-150600.13.3.5 | SUSE-SU-2024:4318-1 |
| SUSE Real Time Module 15 SP6 | kernel-rt +3 | 6.4.0-150600.10.20.1 | SUSE-SU-2024:4314-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Leap 15.6 | dtb-aarch64 +10 | 6.4.0-150600.23.30.1 | SUSE-SU-2024:4318-1 |
| openSUSE Leap 15.6 | kernel-azure +2 | 6.4.0-150600.8.20.1 | SUSE-SU-2024:4316-1 |
| openSUSE Leap 15.6 | kernel-default-base | 6.4.0-150600.23.30.1.150600.12.12.6 | SUSE-SU-2024:4318-1 |
| openSUSE Leap 15.6 | kernel-rt +3 | 6.4.0-150600.10.20.1 | SUSE-SU-2024:4314-1 |
Amazon Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Amazon Linux 2023 | kernel-livepatch-6.1.119-129.201 | 1.0-0.amzn2023 | ALAS2023-2025-802 |
| Amazon Linux 2023 | perf +14 | 6.1.119-129.201.amzn2023 | ALAS2023-2025-802 |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 9 | bpftool | 7.5.0-802.el9_6 | ELSA-2025-6966 |
| Oracle Linux 9 | rv +28 | 5.14.0-570.12.1.0.1.el9_6 | ELSA-2025-6966 |
| Oracle Linux 8 | bpftool +13 | 5.15.0-305.176.4.el9uek | ELSA-2025-20095 |
Advisories 36
- RHSA-2025:6966 Red Hat Security Advisory: kernel security update Red Hat Security Advisories (RHSA) · Nov 13, 2026
- USN-7449-1 linux, linux-aws, linux-azure, linux-azure-6.8, linux-ibm, linux-lowlatency, linux-lowlatency-hwe-6.8, linux-nvidia, linux-nvidia-6.8, linux-nvidia-lowlatency, linux-oem-6.8, linux-oracle, linux-oracle-6.8 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7450-1 linux-gcp, linux-gke, linux-gkeop vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7468-1 linux-azure-nvidia vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7453-1 linux-realtime vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7451-1 linux-aws-6.8 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7524-1 linux-raspi vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7523-1 linux-raspi-realtime vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7452-1 linux-gcp-6.8 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7449-2 linux-hwe-6.8 vulnerabilities Ubuntu Security Notices (USN) · Nov 3, 2026
- USN-7459-1 linux-intel-iotg-5.15 vulnerabilities Ubuntu Security Notices (USN) · Oct 30, 2026
- USN-7459-2 linux-gcp-5.15 vulnerabilities Ubuntu Security Notices (USN) · Oct 30, 2026
- USN-7387-1 linux, linux-aws, linux-azure, linux-gcp, linux-gke, linux-gkeop, linux-ibm, linux-intel-iotg, linux-lowlatency, linux-lowlatency-hwe-5.15, linux-nvidia, linux-oracle, linux-oracle-5.15, linux-raspi vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7387-2 linux-fips, linux-aws-fips, linux-azure-fips, linux-gcp-fips vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7458-1 linux-ibm-5.15 vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7387-3 linux-realtime, linux-intel-iot-realtime vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7388-1 linux-aws-5.15, linux-kvm vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7421-1 linux-azure-5.15, linux-azure-fde-5.15 vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7389-1 linux-nvidia-tegra, linux-nvidia-tegra-igx vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7390-1 linux-xilinx-zynqmp vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- USN-7407-1 linux-hwe-5.15 vulnerabilities Ubuntu Security Notices (USN) · Oct 29, 2026
- WID-SEC-2025-2855 IBM DataPower Gateway: Mehrere Schwachstellen BSI CERT-Bund (WID) · Sep 17, 2026
- WID-SEC-2024-3547 Linux Kernel: Mehrere Schwachstellen ermöglichen nicht spezifizierten Angriff BSI CERT-Bund (WID) · Sep 17, 2026
- SUSE-SU-2025:20163-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Mar 23, 2026
- SUSE-SU-2025:20246-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Mar 23, 2026
- SUSE-SU-2025:20164-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Mar 23, 2026
- SUSE-SU-2025:20247-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Mar 23, 2026
- DLA-4008-1 linux-6.1 - security update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-4075-1 linux - security update Debian Security (DSA / DLA) · Mar 9, 2026
- SUSE-SU-2024:4318-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:4316-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:4387-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Feb 4, 2026
- SUSE-SU-2024:4314-1 Security update for the Linux Kernel SUSE / openSUSE Security Updates · Feb 4, 2026
- ALAS2023-2025-802 Important: kernel security update (Amazon Linux 2023) Amazon Linux Security Center (ALAS) · Oct 2, 2025
- ELSA-2025-6966 Moderate: kernel security update (Oracle Linux 9) Oracle Linux Security Advisories (ELSA) · May 16, 2025
- ELSA-2025-20095 Important: Unbreakable Enterprise kernel security update (Oracle Linux 8) Oracle Linux Security Advisories (ELSA) · Feb 9, 2025
References
- https://git.kernel.org/stable/c/43323a4e5b3f8ccc08e2f835abfdc7ee9da8f6ed
- https://git.kernel.org/stable/c/44f48eb9a6051826227bbd375446064fb2a43c6c
- https://git.kernel.org/stable/c/52c81fd0f5a8bf8032687b94ccf00d13b44cc5c8
- https://git.kernel.org/stable/c/bdc136e2b05fabcd780fe5f165d154eb779dfcb0
- https://git.kernel.org/stable/c/5de195060b2e251a835f622759550e6202167641
- https://project-zero.issues.chromium.org/issues/374117290