cve.bz

CVE-2023-53178 linux linux kernel: Race Condition

4.7 mediumEPSS 0.1%Fix available

Medium (4.7) in linux linux kernel. EPSS 0.1% estimated probability of exploitation activity in the next 30 days.

On this page
In the Linux kernel, the following vulnerability has been resolved: mm: fix zswap writeback race condition The zswap writeback mechanism can cause a race condition resulting in memory corruption, where a swapped out page gets swapped in with data that was written to a different page. The race unfolds like this: 1. a page with data A and swap offset X is stored in zswap 2. page A is removed off the LRU by zpool driver for writeback in zswap-shrink work, data for A is mapped by zpool driver 3. user space program faults and invalidates page entry A, offset X is considered free 4. kswapd stores page B at offset X in zswap (zswap could also be full, if so, page B would then be IOed to X, then skip step 5.) 5. entry A is replaced by B in tree->rbroot, this doesn't affect the local reference held by zswap-shrink work 6. zswap-shrink work writes back A at X, and frees zswap entry A 7. swapin of slot X brings A in memory instead of B The fix: Once the swap page cache has been allocated (case ZSWAP_SWAPCACHE_NEW), zswap-shrink work just checks that the local zswap_entry reference is still the same as the one in the tree. If it's not the same it means that it's either been invalidated or replaced, in both cases the writeback is aborted because the local entry contains stale data. Reproducer: I originally found this by running `stress` overnight to validate my work on the zswap writeback mechanism, it manifested after hours on my test machine. The key to make it happen is having zswap writebacks, so whatever setup pumps /sys/kernel/debug/zswap/written_back_pages should do the trick. In order to reproduce this faster on a vm, I setup a system with ~100M of available memory and a 500M swap file, then running `stress --vm 1 --vm-bytes 300000000 --vm-stride 4000` makes it happen in matter of tens of minutes. One can speed things up even more by swinging /sys/module/zswap/parameters/max_pool_percent up and down between, say, 20 and 1; this makes it reproduce in tens of seconds. It's crucial to set `--vm-stride` to something other than 4096 otherwise `stress` won't realize that memory has been corrupted because all pages would have the same data.

Severity

CVSS 3.1

4.7 medium
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H
EPSS
0.1% (unchanged from 0.1% a week ago; 0.1% 30 days ago) estimated probability of exploitation activity in the next 30 days; 2nd percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: no · Technical impact: partial, assessed 2026-06-10. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-362 Concurrent Execution using Shared Resource with Improper Synchronization (Race Condition)
OWASP Top 10
A06:2025 Insecure Design
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2023-53178 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2023-53178?via=ask-ai-copy and https://cve.bz/cve/CVE-2023-53178?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2023-53178 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
Linux3.11 and later

Fixed in

ProductRelease lineFixed in
Linux6.16.1.30
Linux6.36.3.4
Linuxlater releases6.4

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12linux6.1.37-1DEBIAN-CVE-2023-53178
Debian13, 14linux6.3.7-1DEBIAN-CVE-2023-53178
Ubuntu16.04:LTSlinux-hwe-edgeno fix listedUBUNTU-CVE-2023-53178
Ubuntu18.04:LTSlinux-gcp, linux-hwe, linux-oem and 12 moreno fix listedUBUNTU-CVE-2023-53178
Ubuntu20.04:LTSlinux-gke, linux-gkeop, linux-riscv and 26 moreno fix listedUBUNTU-CVE-2023-53178
Ubuntu22.04:LTSlinux, linux-aws, linux-gcp and 47 moreno fix listedUBUNTU-CVE-2023-53178
Ubuntu24.04:LTSlinux-intel, linux-riscv, linux-oem-6.8 and 7 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuNvidia-BlueField:22.04:LTSlinux-bluefieldno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:14.04:LTSlinux, linux-aws, linux-azure and 1 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:16.04:LTSlinux, linux-aws, linux-gcp and 5 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:18.04:LTSlinux, linux-aws, linux-kvm and 10 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:20.04:LTSlinux, linux-aws, linux-gcp and 19 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:FIPS-preview:22.04:LTS, Pro:FIPS-updates:18.04:LTS, Pro:FIPS-updates:20.04:LTS and 3 morelinux-fips, linux-aws-fips, linux-gcp-fips and 1 moreno fix listedUBUNTU-CVE-2023-53178
UbuntuPro:FIPS-updates:16.04:LTS, Pro:FIPS:16.04:LTSlinux-fipsno fix listedUBUNTU-CVE-2023-53178
1 more for Ubuntu in the JSON and on Ubuntu's page.
Red Hatenterprise_linux:8::baseosperf, kernel, bpftool and 30 more0:4.18.0-553.83.1.el8_10RHSA-2025:19931
Red Hatenterprise_linux:8::crbperf-debuginfo, kernel-debuginfo, bpftool-debuginfo and 7 more0:4.18.0-553.83.1.el8_10RHSA-2025:19931
Red Hatenterprise_linux:8::nfvkernel-rt, kernel-rt-kvm, kernel-rt-core and 12 more0:4.18.0-553.83.1.rt7.424.el8_10RHSA-2025:19932
Red Hatenterprise_linux:8::realtimekernel-rt, kernel-rt-core, kernel-rt-debug and 10 more0:4.18.0-553.83.1.rt7.424.el8_10RHSA-2025:19932
Red Hatenterprise_linux:9::appstreamrv, perf, rtla and 27 more0:5.14.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::appstream, enterprise_linux:9::crb, enterprise_linux:9::nfv and 1 morebpftool-debuginfo0:7.4.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::baseosbpftool, bpftool-debuginfo0:7.4.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::baseoskernel, kernel-64k, kernel-core and 44 more0:5.14.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::crblibperf, perf-debuginfo, kernel-debuginfo and 15 more0:5.14.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::nfvkernel-rt, kernel-rt-kvm, kernel-rt-core and 20 more0:5.14.0-503.11.1.el9_5RHSA-2024:9315
Red Hatenterprise_linux:9::realtimekernel-rt, kernel-rt-core, perf-debuginfo and 18 more0:5.14.0-503.11.1.el9_5RHSA-2024:9315
Red Hatrhel_aus:8.2::baseosperf, kernel, bpftool and 21 more0:4.18.0-193.178.1.el8_2RHSA-2025:23445
24 more for Red Hat in the JSON and on Red Hat's page.
SUSEEnterprise Storage 7.1, Linux Enterprise High Performance Computing 15 SP3-LTSSkernel-64kb, kernel-docs, kernel-syms and 4 more5.3.18-150300.59.221.1SUSE-SU-2025:03626-1
SUSEEnterprise Storage 7.1, Linux Enterprise High Performance Computing 15 SP3-LTSS, Linux Enterprise Micro 5.1 and 3 morekernel-default-base5.3.18-150300.59.221.1.150300.18.132.1SUSE-SU-2025:03626-1
SUSELinux Enterprise High Availability Extension 15 SP3, Linux Enterprise Live Patching 15 SP3, Linux Enterprise Micro 5.1 and 1 morekernel-default5.3.18-150300.59.221.1SUSE-SU-2025:03626-1
SUSELinux Enterprise High Availability Extension 15 SP4, Linux Enterprise Live Patching 15 SP4, Linux Enterprise Micro 5.3 and 1 morekernel-default5.14.21-150400.24.179.1SUSE-SU-2025:03628-1
SUSELinux Enterprise High Availability Extension 15 SP4, Linux Enterprise Live Patching 15 SP4, Linux Enterprise Micro 5.3 and 1 morekernel-default5.14.21-150400.24.194.1SUSE-SU-2026:0617-1
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSSkernel-64kb, kernel-docs, kernel-syms and 3 more5.14.21-150400.24.179.1SUSE-SU-2025:03628-1
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSSkernel-64kb, kernel-docs, kernel-syms and 3 more5.14.21-150400.24.194.1SUSE-SU-2026:0617-1
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSS, Linux Enterprise Micro 5.3 and 3 morekernel-default-base5.14.21-150400.24.194.1.150400.24.98.3SUSE-SU-2026:0617-1
SUSELinux Enterprise High Performance Computing 15 SP4-ESPOS, Linux Enterprise High Performance Computing 15 SP4-LTSS, Linux Enterprise Micro 5.3 and 5 morekernel-default-base5.14.21-150400.24.179.1.150400.24.92.1SUSE-SU-2025:03628-1
SUSELinux Enterprise High Performance Computing 15 SP5-ESPOS, Linux Enterprise High Performance Computing 15 SP5-LTSSkernel-64kb, kernel-docs, kernel-syms and 3 more5.14.21-150500.55.124.1SUSE-SU-2025:03615-1
SUSELinux Enterprise High Performance Computing 15 SP5-ESPOS, Linux Enterprise High Performance Computing 15 SP5-LTSSkernel-64kb, kernel-docs, kernel-syms and 3 more5.14.21-150500.55.136.1SUSE-SU-2026:0474-1
SUSELinux Enterprise High Performance Computing 15 SP5-ESPOS, Linux Enterprise High Performance Computing 15 SP5-LTSS, Linux Enterprise Micro 5.5 and 2 morekernel-default-base5.14.21-150500.55.124.1.150500.6.59.1SUSE-SU-2025:03615-1
36 more for SUSE in the JSON and on SUSE's page.
AlmaLinux8kernel-rt, kernel-rt-core, kernel-rt-debug and 7 more4.18.0-553.83.1.rt7.424.el8_10ALSA-2025:19932
AlmaLinux8perf, kernel, bpftool and 22 more4.18.0-553.83.1.el8_10ALSA-2025:19931
Rocky Linux8kernel0:4.18.0-553.83.1.el8_10RLSA-2025:19931
Rocky Linux8kernel-rt0:4.18.0-553.83.1.rt7.424.el8_10RLSA-2025:19932
Azure Linux2kernelno fix listedAZL-71162
Alpaquitastreamlinux-lts6.6.58-r0BELL-CVE-2023-53178

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; Red Hat Security Data © Red Hat, Inc., CC BY 4.0; SUSE security data, CC BY 4.0; AlmaLinux's OSV database, MIT; Rocky Linux's errata, BSD-3-Clause; Microsoft's Azure Linux vulnerability data, MIT; BellSoft's OSV database, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat · SUSE · Alpaquita.

Red Hat

Red Hat rates this Moderate.

Red Hat's statement

This vulnerability is a race condition in the zswap writeback path that can lead to memory corruption when a swap slot is reused while a writeback is still in progress.

A local unprivileged user can potentially trigger this issue by applying heavy memory pressure and causing frequent zswap evictions.

While exploitation for data leakage or privilege escalation is unlikely, the flaw can result in data integrity issues or system instability under specific conditions.

ProductPackageStateAdvisory
Red Hat Enterprise Linux 7 Extended Lifecycle Supportkernel-rt-0:3.10.0-1160.144.1.rt56.1296.el7Fixed 2025-12-22RHSA-2025:23960
Red Hat Enterprise Linux 7 Extended Lifecycle Supportkernel-0:3.10.0-1160.144.1.el7Fixed 2025-12-22RHSA-2025:23947
Red Hat Enterprise Linux 8kernel-rt-0:4.18.0-553.83.1.rt7.424.el8_10Fixed 2025-11-10RHSA-2025:19932
Red Hat Enterprise Linux 8kernel-0:4.18.0-553.83.1.el8_10Fixed 2025-11-10RHSA-2025:19931
Red Hat Enterprise Linux 8.2 Advanced Update Supportkernel-0:4.18.0-193.178.1.el8_2Fixed 2025-12-17RHSA-2025:23445
Red Hat Enterprise Linux 8.4 Advanced Mission Critical Update Supportkernel-0:4.18.0-305.179.1.el8_4Fixed 2025-12-04RHSA-2025:22752
Red Hat Enterprise Linux 8.4 Extended Update Support Long-Life Add-Onkernel-0:4.18.0-305.179.1.el8_4Fixed 2025-12-04RHSA-2025:22752
Red Hat Enterprise Linux 8.6 Advanced Mission Critical Update Supportkernel-0:4.18.0-372.168.1.el8_6Fixed 2025-11-12RHSA-2025:21084
Red Hat Enterprise Linux 8.6 Telecommunications Update Servicekernel-0:4.18.0-372.168.1.el8_6Fixed 2025-11-12RHSA-2025:21084
Red Hat Enterprise Linux 8.6 Update Services for SAP Solutionskernel-0:4.18.0-372.168.1.el8_6Fixed 2025-11-12RHSA-2025:21084
Red Hat Enterprise Linux 8.8 Telecommunications Update Servicekernel-0:4.18.0-477.118.1.el8_8Fixed 2025-11-12RHSA-2025:21083
Red Hat Enterprise Linux 8.8 Update Services for SAP Solutionskernel-0:4.18.0-477.118.1.el8_8Fixed 2025-11-12RHSA-2025:21083
Red Hat Enterprise Linux 9kernel-0:5.14.0-503.11.1.el9_5Fixed 2024-11-12RHSA-2024:9315
Red Hat Enterprise Linux 9.0 Update Services for SAP Solutionskernel-0:5.14.0-70.153.1.el9_0Fixed 2025-11-12RHSA-2025:21091
Red Hat Enterprise Linux 9.0 Update Services for SAP Solutionskernel-rt-0:5.14.0-70.153.1.rt21.225.el9_0Fixed 2025-11-12RHSA-2025:21136
Red Hat Enterprise Linux 9.2 Update Services for SAP Solutionskernel-0:5.14.0-284.146.1.el9_2Fixed 2025-11-12RHSA-2025:21051
Red Hat Enterprise Linux 9.2 Update Services for SAP Solutionskernel-rt-0:5.14.0-284.146.1.rt14.431.el9_2Fixed 2025-11-12RHSA-2025:21128
Red Hat Enterprise Linux 10kernelNot affected
Red Hat Enterprise Linux 6kernelNot affected
Red Hat Enterprise Linux 9kernel-rtAffected
1 more in the JSON and on Red Hat's page.

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2023-53178.

Attack patterns (CAPEC)

  • CAPEC-26 Leveraging Race Conditions Likelihood: High · Severity: High
  • CAPEC-29 Leveraging Time-of-Check and Time-of-Use (TOCTOU) Race Conditions Likelihood: High · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON