{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-139217","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","state":"PUBLISHED","assignerShortName":"Linux","dateReserved":"2026-11-30T13:22:15.921Z","datePublished":"2026-11-30T13:32:40.315Z","dateUpdated":"2026-12-01T05:41:50.316Z"},"containers":{"cna":{"providerMetadata":{"orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux","dateUpdated":"2026-12-01T05:41:50.316Z"},"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nntfs: reject index blocks with a too small entries offset\n\nIndex blocks read from the volume are checked for a plausible header, but\nnothing keeps a block from placing its entries closer to the header than\nntfs_ib_alloc() does when it creates one.  The allocation adds the update\nsequence array, one entry per 512-byte sector plus the terminator, to the\nindex header and aligns the result to 8 bytes, so the first entry of a\n4096-byte block starts at offset 40, while a corrupt block may declare 16.\n\nntfs_ib_copy_tail() then copies the entries that follow the median entry\nfrom the source block into a freshly allocated destination.  The tail is\nsized as index_length minus entries_offset and the median entry, both from\nthe source, while the destination only has allocated_size minus the\ncanonical offset of room.  With the values above the tail is 4040 bytes\nand the destination holds 4032, so the last 8 bytes are written past the\nend of the new allocation, with contents taken from the mounted image.\n\nReject such a block when it is read: entries_offset must not be smaller\nthan the canonical offset for the block size.  Derive it from block_size\nrather than from the block's own usa_count, which post_read_mst_fixup()\ntreats as \"not protected\" when it does not match the block size, and use\nthe same helper in ntfs_ib_alloc() so both stay in sync."}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The bad entries_offset comes from an on-disk INDX block of a crafted NTFS volume, read by ntfs_ib_read(). The trigger is a local VFS create/mkdir/link/rename: ntfs_index_add_filename -> ntfs_ie_add -> ntfs_ib_split -> ntfs_ib_copy_tail. No protocol message carries the index block.\nAC:L - The image author controls every input. An END-only leaf with entries_offset=16 and index_length=4072 forces a split on the next insert. ntfs_ie_get_median() then returns the END entry, so the memcpy length (4040 > 4032) follows directly from the image every time, with no race.\nPR:N - ntfs_fs_type is FS_REQUIRES_DEV|FS_ALLOW_IDMAP without FS_USERNS_MOUNT, so the attacker cannot mount it and does not need to. They only supply the media or image. The mount is the victim's or automounter's action, scored under UI:R rather than as attacker privilege.\nUI:R - The overflow happens only after a victim or udisks2/vold mounts the attacker's NTFS image read-write and a name is then added to the crafted directory. Merely attaching the volume does not reach ntfs_ib_copy_tail().\nS:U - The overflow corrupts the host kernel heap inside the same kernel authority as fs/ntfs. It crosses no VM, IOMMU or sandbox boundary.\nC:H - ntfs_ib_copy_tail() writes image-chosen bytes past kvzalloc(block_size): 8 bytes into the next kmalloc-4k object at 4K blocks, up to 248 bytes at 64K. Corrupting the first qword of a neighbouring object, often a pointer, can be groomed into reading kernel memory.\nI:H - This is a heap out-of-bounds write. The bytes after the END entry up to index_length are never validated by ntfs_index_entries_inconsistent() and are copied raw past the new index block, overwriting an adjacent slab object's leading fields with attacker values that can hijack control flow.\nA:H - Overwriting the start of the adjacent kmalloc-4k object corrupts slab state or a live object. KASAN, a slab freelist check or a later dereference then oopses or panics on the ordinary create/mkdir path."}]}],"affected":[{"product":"Linux","vendor":"Linux","defaultStatus":"unaffected","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ntfs/index.c"],"versions":[{"version":"0a8ac0c1fa0b99a5b29002bc7f232ed7eafddef0","lessThan":"bae87fc0e80c50f065f1feca232e38e3292be425","status":"affected","versionType":"git"},{"version":"0a8ac0c1fa0b99a5b29002bc7f232ed7eafddef0","lessThan":"20e14268ef410cbabff54a79405813a8b9ce8e89","status":"affected","versionType":"git"}]},{"product":"Linux","vendor":"Linux","defaultStatus":"affected","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ntfs/index.c"],"versions":[{"version":"7.1","status":"affected"},{"version":"0","lessThan":"7.1","status":"unaffected","versionType":"semver"},{"version":"7.3.6","lessThanOrEqual":"7.3.*","status":"unaffected","versionType":"semver"},{"version":"7.4-rc1","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"7.1","versionEndExcluding":"7.3.6"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"7.1","versionEndExcluding":"7.4-rc1"}]}]}],"references":[{"url":"https://git.kernel.org/stable/c/bae87fc0e80c50f065f1feca232e38e3292be425"},{"url":"https://git.kernel.org/stable/c/20e14268ef410cbabff54a79405813a8b9ce8e89"}],"title":"ntfs: reject index blocks with a too small entries offset","x_generator":{"engine":"bippy-1.2.0"}}}}