CVE-2026-143125: ntfs: do not read an index block outside $INDEX_ALLOCATION
In the Linux kernel, the following vulnerability has been resolved:
ntfs: do not read an index block outside $INDEXALLOCATION
A directory whose $INDEXROOT has a child node but whose $INDEXALLOCATION is missing or damaged gets an empty index inode from ntfsreadlockedindexinode(): size 0 and not non-resident. ntfslookupinodebyname() still follows the child node and reads a folio from that inode while it holds the mft record lock of the directory.
Since the resident iomap read started to take baseni->mreclock, that read waits for a lock the caller already holds:
INFO: task init:1 is blocked on a mutex likely owned by task init:1. mutexlock ntfsreadiomapbegin ntfsreadiomapnext iomapreadfolio ntfsreadfolio ntfslookupinodebyname ntfslookup
The task never returns, and neither does anything else that needs the directory's mft record.
It takes one corrupted byte on an image from mkntfs: change the first byte of the type of the $INDEXALLOCATION attribute header of a directory with index blocks from 0xa0 to 0x00. The first lookup in that directory hangs.
Check that the index inode is non-resident and that the vcn lies inside it before every index block read, and fail with -EIO otherwise. This also rejects a negative vcn, which was only checked on later descents.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
Before every index-block read, verify that the index inode is non-resident and the VCN is non-negative and within $INDEX_ALLOCATION; otherwise fail with -EIO.