HIGH Introduced in 7.1
ntfs IndexRoot OOB
CVE-2026-90133
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
KernelScan AI6.5MEDIUM
01Description
In the Linux kernel, the following vulnerability has been resolved: ntfs: Fix index_root heap OOB write in ntfs_ir_to_ib() ntfs_ir_to_ib copies all entries from index_root into a freshly allocated index_block_size-byte buffer without verifying that the entries fit in the available space. The entries in index_root may be larger than the usable entry space in the index block. This can cause OOB writes past the end of the allocation. The validator ntfs_index_root_inconsistent() checks that entries are self-consistent within the IR value, but never cross-checks them against index_block_size. There is no bounds check in ntfs_ir_to_ib() before the memcpy. Fixing this at the sink in ntfs_ir_to_ib() since ntfs_index_root_inconsistent() validates the logical consistency of index_root as a structure and a root with large entries is a structurally valid root. The bug is a size conflict of ntfs_ir_to_ib(). Also, the validator is called once per inode load in ntfs_read_locked_inode() while ntfs_ir_to_ib() is only called during a reparent, a check there adds no overhead to the common path. Moreover, even a future call path that bypasses the validator would still be protected. With NULL as first parameter of ntfs_error(), the volume error flag is never set by this call, so the device name will be absent from the error message. In any case, that the caller, ntfs_ir_reparent(), prints an error message that includes the device name on NULL returns. I think this is the best solution available without adding 'struct super_block *sb' as a parameter to ntfs_ir_to_ib(). This heap out-of-bounds write is triggered by a crafted filesystem image, which is not in the kernel threat model, anyway, fixing memory errors would be nice to keep things secure.
02KernelScan AI Analysis
Risk summary
A heap out-of-bounds write in the NTFS index handling code can be triggered by a crafted filesystem image. An attacker who can get a malicious NTFS image mounted — via physical media insertion or by a privileged user performing a manual mount — can corrupt kernel heap memory, potentially leading to code execution or a system crash. Products that do not mount untrusted NTFS images or that restrict physical access to removable media ports are not at risk.
Vulnerability analysis
When converting directory index entries from an index root into an index block buffer during a directory reparent operation, the NTFS filesystem driver copies all entries into the newly allocated buffer without first verifying that they fit within the usable space of that buffer. A crafted filesystem image can contain index entries whose total size exceeds the capacity of the destination index block, causing the copy to write past the end of the heap allocation. The fix adds a bounds check before the copy operation, freeing the buffer and returning an error if the entries would exceed the available capacity. This vulnerability is reachable only by mounting a crafted NTFS filesystem image, which requires either physical access to insert removable media that triggers automount or root-level access to perform a manual mount.
Lifecycle
03Fix Versions
| Branch | Introduced | Fixed in | Patch commit |
|---|---|---|---|
| 7.2 | 7.1 | 7.2.6 | 825dec512093 |
| mainline | 7.1 | 7.3-rc1 | dc09bf79b76f |