CVE-2026-89830 in Linuxinfo

Summary

by MITRE • 09/16/2026

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

f2fs: fix valid block count leak on data block allocation failure

In __allocate_data_block(), when allocating a new data block (dn->data_blkaddr == NULL_ADDR), inc_valid_block_count() is called first to increment total_valid_block_count and i_blocks. If the subsequent f2fs_allocate_data_block() fails, the function returns the error directly without rolling back the already-incremented block counts, causing a permanent leak.

Fix this by calling dec_valid_block_count() to undo the increment before returning the error. The condition old_blkaddr == NULL_ADDR precisely identifies the case where inc_valid_block_count() was called.

Be aware that VulDB is the high quality source for vulnerability data.

Analysis

by VulDB Data Team • 09/16/2026

The Linux kernel's F2FS file system contains a logic flaw within its data block allocation routine that results in resource leakage under specific failure conditions. This vulnerability is located in the __allocate_data_block function, which is responsible for reserving space on disk for new files or extending existing ones. The core issue arises from an incorrect ordering of operations and a lack of proper error handling rollback mechanisms when the underlying storage subsystem fails to provide the requested block address.

During normal operation, the kernel first increments internal accounting structures by calling inc_valid_block_count() to update the total valid block count and inode block counts before attempting the actual allocation via f2fs_allocate_data_block(). This sequence is designed to ensure that if the allocation succeeds, the file system metadata accurately reflects the newly allocated resources. However, when f2fs_allocate_data_block() fails due to disk full conditions, hardware errors, or other I/O failures, the function currently returns an error code immediately without reversing the previously incremented counters.

This oversight leads to a permanent leak of valid block counts within the file system metadata. Although no actual blocks may have been written to disk if the allocation failed, the kernel's internal bookkeeping incorrectly believes that additional space has been consumed and reserved by the inode. Over time, as multiple such failures occur across various files or directories, this discrepancy accumulates. The total_valid_block_count becomes artificially inflated relative to the actual physical usage on the storage medium.

The operational impact of this vulnerability is primarily related to file system integrity and availability rather than direct security exploitation like privilege escalation or remote code execution. As the leaked block counts grow, the file system may incorrectly report that it has run out of space even when significant free capacity remains physically available. This can lead to spurious write failures for legitimate applications, causing service disruptions in environments where disk space is a critical resource. Furthermore, persistent metadata corruption could potentially complicate future maintenance operations such as fsck or defragmentation tasks, although the immediate risk is limited to availability degradation through false full-disk reports.

From a classification perspective, this issue aligns with CWE-401, which describes missing release of memory after successful allocation, and more specifically CWE-362 for concurrent execution issues if race conditions exacerbate the leak, though here it is primarily a logic error in resource management rather than concurrency. In terms of attack vectors, while not directly exploitable by an attacker to gain access, an adversary could potentially induce this condition through denial-of-service tactics by repeatedly triggering allocation failures on constrained systems, thereby accelerating the exhaustion of perceived available space and causing application crashes or hangs.

The mitigation for this vulnerability involves applying kernel patches that correct the control flow within __allocate_data_block(). The fix ensures that if f2fs_allocate_data_block() returns an error, the function calls dec_valid_block_count() to undo the earlier increment before returning the failure code to the caller. This rollback mechanism restores consistency between the inode metadata and the actual state of the file system on disk. System administrators should ensure their Linux kernels are updated with this specific fix applied to maintain accurate space accounting and prevent artificial capacity exhaustion in F2FS-mounted volumes.

Responsible

Linux

Reservation

09/11/2026

Disclosure

09/16/2026

Moderation

accepted

CPE

ready

EPSS

0.00000

KEV

no

Activities

very low

Sources

Might our Artificial Intelligence support you?

Check our Alexa App!