Vulnerability · Published Feb 14, 2026 · Assigned by Linux

CVE-2026-23161mm/shmem, swap: fix race of truncate and swap entry split

High 7.3

In plain English

A high-severity security flaw in Linux from Linux. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.1% (higher than 1% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)7.3High
Exploit odds (30 days)0.1%top 99.0% of all CVEs
Exploited in the wildNo reportsnot in CISA KEV
Attack toolingNoneno public tooling known

Official description

In the Linux kernel, the following vulnerability has been resolved: mm/shmem, swap: fix race of truncate and swap entry split The helper for shmem swap freeing is not handling the order of swap entries correctly. It uses xa_cmpxchg_irq to erase the swap entry, but it gets the entry order before that using xa_get_order without lock protection, and it may get an outdated order value if the entry is split or changed in other ways after the xa_get_order and before the xa_cmpxchg_irq. And besides, the order could grow and be larger than expected, and cause truncation to erase data beyond the end border. For example, if the target entry and following entries are swapped in or freed, then a large folio was added in place and swapped out, using the same entry, the xa_cmpxchg_irq will still succeed, it's very unlikely to happen though. To fix that, open code the Xarray cmpxchg and put the order retrieval and value checking in the same critical section. Also, ensure the order won't exceed the end border, skip it if the entry goes across the border. Skipping large swap entries crosses the end border is safe here. Shmem truncate iterates the range twice, in the first iteration, find_lock_entries already filtered such entries, and shmem will swapin the entries that cross the end border and partially truncate the folio (split the folio or at least zero part of it). So in the second loop here, if we see a swap entry that crosses the end order, it must at least have its content erased already. I observed random swapoff hangs and kernel panics when stress testing ZSWAP with shmem. After applying this patch, all problems are gone.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:13linux6.12.69-1DEBIAN-CVE-2026-23161
Debian:14linux6.18.9-1DEBIAN-CVE-2026-23161
Ubuntu:25.10linuxno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-allwinner-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-awsno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-aws-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-aws-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-aws-6.17no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-aws-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-aws-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-azureno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-azure-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-azure-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-azure-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-azure-6.176.17.0-1021.21~24.04.1UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-azure-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-azure-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-azure-fdeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-azure-fde-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-azure-fde-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-azure-fde-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-azure-nvidia-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-gcpno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-gcp-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-gcp-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-gcp-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-gcp-6.176.17.0-1021.24~24.04.1UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-gcp-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-gcp-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-hwe-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-hwe-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-hwe-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-hwe-6.176.17.0-41.41~24.04.1UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-hwe-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-hwe-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-intel-iot-realtimeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-lowlatency-hwe-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-lowlatency-hwe-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-lowlatency-hwe-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-nvidia-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-nvidia-6.176.17.0-1031.31UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-nvidia-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-nvidia-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-oem-5.17no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-oem-6.0no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-oem-6.1no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oem-6.11no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oem-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oem-6.176.17.0-1030.30UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-oem-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oem-6.8no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-oracleno fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oracle-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-oracle-6.176.17.0-1019.19~24.04.3UBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-oracle-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-raspino fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-raspi-realtimeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-realtimeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-realtimeno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-riscvno fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-riscvno fix listedUBUNTU-CVE-2026-23161
Ubuntu:25.10linux-riscvno fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-riscv-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-riscv-6.14no fix listedUBUNTU-CVE-2026-23161
Ubuntu:24.04:LTSlinux-riscv-6.17no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-riscv-6.5no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-starfive-5.19no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-starfive-6.2no fix listedUBUNTU-CVE-2026-23161
Ubuntu:22.04:LTSlinux-starfive-6.5no fix listedUBUNTU-CVE-2026-23161

Affected products (as reported)

VendorProductVersions
Linux Linux 809bc86517cc408b5b8cb8e08e69096639432bc8 – before a99f9a4669a04662c8f9efe0e62cafc598153139809bc86517cc408b5b8cb8e08e69096639432bc8 – before b23bee8cdb7aabce5701a7f57414db5a354ae8ed809bc86517cc408b5b8cb8e08e69096639432bc8 – before 8a1968bd997f45a9b11aefeabdd1232e1b6c7184
Linux Linux 6.12

References