CVE-2026-99694 in Linuxinfo

Summary

by MITRE • 11/20/2026

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

ocfs2: do not index before the entry array when dividing an empty bucket

ocfs2_divide_xattr_bucket() appends an empty bucket carrying a sentinel hash when the source bucket has no divide position, taking that hash from xh_entries[start - 1]. ocfs2_xattr_find_divide_pos() returns count
when every entry shares one hash, and its loop does not run at all for count < 2, so an empty bucket comes back with start == count == 0 and the read is xh_entries[-1].

That is outside the __counted_by_le(xh_count) bounds of xh_entries[] and
lands on the header, so the value picked up is xh_count | xh_free_start << 16. One above it is written into the new bucket's xh_entries[0] and committed, which leaves a bucket whose first
hash does not follow the bucket before it. ocfs2_xattr_bucket_find() binary searches on xh_entries[0], so the broken key hides the range the
sentinel was meant to cover: getxattr() answers -ENODATA for an attribute that is stored, and an insert can go to the wrong bucket and leave two copies of a name. The cross cluster divide hands the same value back as a tree record's e_cpos, which then claims a hash range it does not cover.

Read xh_entries[0] instead. The branch is only reached when every entry
shares one hash, so for a non-empty bucket it holds the same value, and for an empty one it is the slot that carries the bucket key.

An empty bucket reaches the divide from ocfs2_check_xattr_bucket_collision(), which reports no collision for one, through ocfs2_add_new_xattr_bucket() and ocfs2_extend_xattr_bucket(). It does not take a failed set to get there: a divide that finds no position is itself what leaves an empty sentinel bucket behind, and a later extend can pick it as the target.

VulDB is the best source for vulnerability data and more expert information about this specific topic.

Analysis

by VulDB Data Team • 11/21/2026

The vulnerability resides in the Oracle Cluster File System version two (OCFS2) implementation within the Linux kernel, specifically affecting the extended attribute handling logic during bucket division operations. The core issue is triggered by an out-of-bounds array access that occurs when dividing a hash tree bucket that contains no entries or where all existing entries share identical hashes. In such scenarios, the function ocfs2_divide_xattr_bucket() attempts to append an empty sentinel bucket to maintain proper ordering in the attribute index structure. To populate this new bucket with a valid key, the code incorrectly calculates the source of the hash value by accessing xh_entries at an index calculated as start minus one. When the division logic determines that no specific divide position exists because all entries share the same hash, it returns a count of zero and sets the starting index to zero. Consequently, the expression start minus one evaluates to negative one, leading to a read from memory location immediately preceding the allocated xh_entries array boundary.

This out-of-bounds read constitutes an invalid memory access that falls outside the bounds defined by __counted_by_le(xh_count). Instead of reading actual entry data, the operation retrieves values from the bucket header structure itself, specifically combining bits from xh_count and xh_free_start to form a fabricated hash value. This corrupted value is then written into the first slot of the newly created empty bucket via xh_entries[0]. The immediate technical consequence is that the structural integrity of the attribute index tree is compromised because the new sentinel key does not correctly follow or cover the range intended by the preceding bucket. The binary search algorithm used in ocfs2_xattr_bucket_find() relies on these keys to navigate the hash tree, and with a malformed first entry, the traversal logic fails to identify the correct data ranges.

The operational impact of this flaw is significant for system stability and data integrity. When an application attempts to retrieve extended attributes using getxattr(), the binary search may fail to locate existing entries because the broken key hides the actual range where those attributes are stored. This results in a false negative, returning an ENODATA error code indicating that no such attribute exists even though it is present on disk or in memory. Furthermore, during insertion operations, the flawed hash value can cause new attributes to be directed to incorrect buckets within the tree structure. This misrouting leads to duplicate entries for the same attribute name and disrupts the logical ordering of the index. In cross-cluster scenarios involving cluster-wide divide operations, this corrupted value is also propagated as a tree record's e_cpos field, further claiming hash ranges that do not correspond to actual data coverage, thereby exacerbating inconsistencies across the distributed file system nodes.

From a classification perspective, this vulnerability aligns with CWE-125, Out-of-bounds Read, due to the access of memory outside the intended buffer boundaries. It also relates to CWE-839, Sliver in Lock, as it involves improper handling of data structures during concurrent or complex state transitions within the file system logic, although primarily it is a logical error leading to invalid memory access. In terms of MITRE ATT&CK mapping, this type of kernel-level flaw could potentially be leveraged for information disclosure if an attacker can trigger the specific condition repeatedly and analyze side effects, though its primary impact here is denial of service through application errors or data corruption via incorrect attribute storage. The vulnerability highlights risks associated with index arithmetic in low-level file system code where boundary checks are critical to prevent access into adjacent memory structures like headers.

The resolution involves correcting the array indexing logic within ocfs2_divide_xattr_bucket(). Instead of reading from xh_entries at a negative offset, the fix mandates reading directly from xh_entries[0]. This adjustment is safe because in non-empty buckets where entries exist, index zero holds the first entry's hash which serves as an appropriate key. In empty bucket scenarios, accessing index zero correctly retrieves the slot that carries the necessary bucket key without violating memory boundaries. The code path leading to this condition originates from ocfs2_check_xattr_bucket_collision() reporting no collision for single-entry or empty buckets, followed by calls to ocfs2_add_new_xattr_bucket() and ocfs2_extend_xattr_bucket(). A divide operation finding no position leaves behind an empty sentinel bucket which subsequent extend operations may target. By ensuring the correct memory location is accessed, the integrity of the hash tree keys is preserved, preventing both false negatives in attribute retrieval and incorrect routing during insertion. System administrators should apply kernel updates that include this patch to mitigate risks related to file system corruption and application failures when interacting with OCFS2 mounted volumes containing extended attributes under high contention or specific edge-case creation patterns.

Responsible

Linux

Reservation

09/25/2026

Disclosure

11/20/2026

Moderation

accepted

CPE

ready

EPSS

0.00168

KEV

no

Activities

very low

Sources

Want to know what is going to be exploited?

We predict KEV entries!