Skip to main content
Vulnerability Database/CVE-2026-98139

CVE-2026-98139: Linux Kernel NTFS Privilege Escalation

CVE-2026-98139 is a privilege escalation vulnerability in the Linux kernel NTFS filesystem that corrupts free space accounting. This article covers the technical details, affected versions, and mitigation steps.

Published:

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

CVE-2026-98139 Overview

CVE-2026-98139 is a Linux kernel vulnerability in the NTFS filesystem driver. The flaw resides in ntfs_cluster_free_from_rl_nolock(), which miscounts cleared cluster runs when freeing clusters. When ntfs_bitmap_clear_run() fails, the function still adds the run's length to nr_freed, inflating vol->free_clusters. This corrupts statfs output and the allocator's free-space accounting. The upstream fix changes the logic to only count runs whose bitmap clear operation actually succeeded.

Critical Impact

Incorrect free-cluster accounting in NTFS volumes can cause filesystem allocator corruption, inaccurate disk usage reporting, and potential data integrity issues on mounted NTFS volumes.

Affected Products

  • Linux kernel NTFS filesystem driver
  • Systems mounting NTFS volumes using the in-kernel driver
  • Specific affected and patched kernel versions are tracked in the upstream stable commits

Discovery Timeline

  • 2026-09-25 - CVE-2026-98139 published to NVD
  • 2026-09-30 - Last updated in NVD database

Technical Details for CVE-2026-98139

Vulnerability Analysis

The defect lives in the NTFS cluster-free path. ntfs_cluster_free_from_rl_nolock() iterates over runlist entries and calls ntfs_bitmap_clear_run() on each run to release clusters back to the free pool. The function tracks errors through a bookkeeping condition designed to record the first failure.

When that bookkeeping condition evaluates false, the function unconditionally adds the current run's length to nr_freed. This path is also taken when a later ntfs_bitmap_clear_run() fails with the same errno as a previous failure, or when any failure occurs after a non-ENOMEM error was already recorded.

Because ntfs_bitmap_clear_run() rolls back its partial modifications on failure, no bits are actually cleared in the on-disk bitmap. The driver nonetheless credits those clusters as freed. The result is that vol->free_clusters grows beyond the true free count, corrupting both statfs output and the allocator's internal gate for free space decisions. This is an input validation and accounting error, closely related to improper error handling [CWE-754].

Root Cause

The root cause is a flawed conditional check that conflates error-recording state with per-run success state. The code treats "we already recorded an error" as equivalent to "this run succeeded," so subsequent failures silently inflate the freed-cluster counter.

Attack Vector

Triggering the condition requires ntfs_bitmap_clear_run() to fail during a cluster-free operation on an NTFS volume. This typically depends on filesystem state, I/O errors, or corrupted metadata. The vulnerability is a local correctness and data-integrity issue in the kernel NTFS driver rather than a remotely exploitable code execution flaw. No public exploit is listed, and the EPSS data indicates very low exploitation probability.

See the upstream commits for the exact code paths: Kernel Git Commit 7eb97d88 and Kernel Git Commit be9e89cc.

Detection Methods for CVE-2026-98139

Indicators of Compromise

  • Discrepancy between statfs / df reported free space and the actual free space on NTFS volumes.
  • Kernel log messages from the ntfs module reporting bitmap clear failures during cluster free operations.
  • Allocator behavior that permits writes which later fail with no-space errors despite reported free capacity.

Detection Strategies

  • Compare df output against on-disk NTFS bitmap state using offline NTFS tools (for example ntfsinfo) to detect drift.
  • Monitor dmesg and /var/log/kern.log for NTFS driver warnings around ntfs_cluster_free_from_rl_nolock and ntfs_bitmap_clear_run.
  • Inventory running kernel versions across Linux fleets and flag hosts not yet patched to a fixed stable release.

Monitoring Recommendations

  • Centralize kernel log collection and alert on NTFS error patterns indicating failed bitmap operations.
  • Track kernel package versions as part of configuration management to confirm backported fixes land on all hosts mounting NTFS.
  • Validate filesystem consistency after unexpected I/O errors on NTFS volumes.

How to Mitigate CVE-2026-98139

Immediate Actions Required

  • Apply the upstream stable kernel updates referenced in the two kernel.org commits as soon as distribution builds are available.
  • Identify systems that mount NTFS volumes via the in-kernel driver and prioritize those for patching.
  • Unmount and run offline consistency checks on NTFS volumes that have logged bitmap clear failures.

Patch Information

The fix is upstream in the Linux kernel. See Kernel Git Commit 7eb97d88 and Kernel Git Commit be9e89cc. The change updates ntfs_cluster_free_from_rl_nolock() to add a run's length to nr_freed only when ntfs_bitmap_clear_run() returned success for that run.

Workarounds

  • Avoid read-write use of the in-kernel NTFS driver on affected kernels where feasible; prefer read-only mounts for NTFS volumes until patched.
  • Where supported, use a userspace alternative such as ntfs-3g via FUSE for read-write NTFS access on unpatched hosts.
  • Minimize operations that trigger large cluster-free paths on NTFS volumes until the kernel is updated.
bash
# Example: mount NTFS volume read-only as a temporary mitigation
mount -t ntfs -o ro /dev/sdX1 /mnt/ntfs

# Verify running kernel version against your distribution's fixed release
uname -r

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Sources: National Vulnerability Database, CISA KEV, Exploit-DB

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.