Junglewise Threat Intelligence

CVE-2023-53838: Linux kernel f2fs race condition in atomic write abort synchronization

CVE-2023-53838 · Severity: high · CVSS 7.8 · Published 2025-12-09

Technologies: Linux Kernel. Vendors: Linux.

Executive brief

The Linux kernel's f2fs filesystem implements atomic writes used by database systems and applications requiring guaranteed write consistency. A race condition in the atomic write abort handler could allow concurrent operations to corrupt file data or trigger system crashes. This affects all Linux systems using f2fs, particularly database servers and embedded devices relying on this filesystem.

Technical details

The vulnerability is a race condition (CWE-362) in f2fs atomic write abort synchronization. The vulnerable code path occurs when multiple threads attempt to abort atomic write operations concurrently without proper locking of the copy-on-write (COW) inode. The fix adds inode_lock() around f2fs_abort_atomic_write() calls in f2fs_release_file() and f2fs_file_flush(), and makes COW inodes reusable throughout the atomic file's lifetime by checking for existing COW inodes rather than creating new ones. An attacker with local filesystem access can trigger concurrent atomic write operations to exploit this race, potentially causing data corruption or denial of service. The patch was merged upstream in Linux kernel 2023-02-14 and backported to stable kernels.

Affected products

  • Linux Linux kernel All versions with f2fs filesystem support (primarily 5.18 and later, backported to stable branches)

Timeline

  • 2023-02-09: disclosed: Issue reported by syzbot
  • 2023-02-14: patched: Upstream commit a46bebd502fe1a3bd1d22f64cedd93e7e7702693 merged by Jaegeuk Kim
  • 2023-03-11: patched: Stable kernel backport (commit 102b82708c1523b36d421cb8687746906069bc17) merged by Greg Kroah-Hartman

References

Related threats