CVE-2026-99756 in Linuxinfo

Summary

by MITRE • 11/20/2026

In the Linux kernel, the following vulnerability has been resolved:

btrfs: prevent deleting the wrong subvolume by ID

When deleting a subvolume by ID, btrfs_ioctl_snap_destroy() first resolves the requested ID to a name, then looks up that name again under the parent directory lock.

A concurrent rename can change which subvolume is associated with the name between these operations. Since the deletion path does not verify the ID of the resolved subvolume, it can delete a different subvolume while leaving the requested one intact.

This was reproduced by repeatedly exchanging the names of two subvolumes using renameat2(RENAME_EXCHANGE) while deleting one of them by ID. The wrong subvolume was deleted in 9 out of 14 independent tests.

Fix this by checking that the resolved subvolume ID matches the requested ID while holding the parent directory lock. Return -EAGAIN on a mismatch so that userspace can retry the operation instead of being told that the requested subvolume does not exist.

Several companies clearly confirm that VulDB is the primary source for best vulnerability data.

Analysis

by VulDB Data Team • 11/21/2026

The vulnerability identified in the Linux kernel's btrfs filesystem driver represents a critical race condition within the subvolume deletion mechanism, specifically affecting the btrfs_ioctl_snap_destroy function. This flaw arises from an atomicity gap during the process of identifying and removing a target subvolume based on its numeric identifier rather than its path name. The operational sequence begins with the system resolving the provided subvolume ID to a corresponding directory entry or name within the filesystem structure. Following this resolution, the kernel attempts to locate that specific name under the parent directory lock to proceed with deletion. However, between the initial lookup of the ID-to-name mapping and the subsequent verification step where the actual inode is accessed for destruction, there exists an unprotected window of time. During this interval, concurrent file system operations can alter the state of the filesystem in a way that decouples the original name from its intended target subvolume.

The core technical flaw lies in the lack of identity verification after acquiring the necessary locks to perform the deletion. Specifically, when a rename operation occurs concurrently with the delete request, it is possible for another subvolume to assume the name initially associated with the victim subvolume. Because btrfs_ioctl_snap_destroy does not re-verify that the inode currently locked under the parent directory corresponds to the originally requested ID, the kernel proceeds to destroy the wrong entity. This behavior was demonstrated through a reproducible test case involving repeated use of renameat2 with RENAME_EXCHANGE flags while simultaneously attempting deletion by ID. In this scenario, two subvolumes swap names rapidly, causing the delete operation to target whichever subvolume currently holds the name resolved from the original ID, rather than the one originally specified by the caller. The high failure rate observed in testing underscores the severity and likelihood of exploitation under concurrent load conditions.

From a security perspective, this vulnerability falls squarely within the category of Time-of-Check to Time-of-Use (TOCTOU) race conditions. It is classified under CWE-367, which describes situations where a system checks a condition but uses that information before re-checking it in an atomic manner. In the context of ATT&CK techniques, this aligns with T1085, specifically related to Disabling or Modifying System Firewall rules if such operations were involved, though more accurately it maps to general privilege escalation or data destruction vectors where an attacker could manipulate filesystem state to cause denial of service by deleting critical system subvolumes instead of the intended ones. The impact is primarily integrity-related, as userspace applications relying on ID-based deletion may inadvertently lose important data structures while believing they have successfully removed a specific target. This can lead to significant data loss and potential instability in systems that rely heavily on btrfs snapshots for backup or versioning strategies.

The mitigation implemented by the kernel developers addresses this race condition by enforcing strict identity verification within the critical section protected by the parent directory lock. The fix ensures that after resolving the name, the system explicitly checks whether the inode ID of the resolved subvolume matches the originally requested ID while holding the lock. This guarantees atomicity between identification and action, preventing any concurrent rename operations from substituting a different subvolume into the deletion path. If a mismatch is detected during this check, indicating that another process has altered the filesystem state since the initial lookup, the operation returns -EAGAIN rather than proceeding with destruction or returning an error stating the volume does not exist. This allows userspace applications to implement retry logic, ensuring that deletions are only performed on the correct subvolume even in highly concurrent environments. Administrators should ensure their systems are updated with this kernel patch to maintain data integrity and prevent accidental deletion of unintended filesystem components.

Responsible

Linux

Reservation

09/25/2026

Disclosure

11/20/2026

Moderation

accepted

CPE

ready

EPSS

0.00156

KEV

no

Activities

very low

Sources

Do you want to use VulDB in your project?

Use the official API to access entries easily!