{"id":"CVE-2026-98443","state":"PUBLISHED","title":"xfs: fix cursor and pointer handling when recovering iunlink buckets","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nxfs: fix cursor and pointer handling when recovering iunlink buckets\n\nLOLLM pointed out a bug in xlog_recover_iunlink_bucket:\n\n1. We don't null out prev_ip after releasing it, which can lead to UAF\n   problems if the inodegc flush call in the loop fails.\n\nat which point I noticed even more bugs:\n\n2. If the inodegc flush inside the loop fails, we also leak @ip.\n\n3. We set prev_agino to agino having already advanced agino, which\n   results in inodes with i_prev_unlinked set to itself.\n\n4. If we exit the bottom of the loop with prev_ip set, then prev_ip\n   aliases ip and we also set its i_prev_unlinked to itself.\n\nBugs 3 and 4 introduce loops into the unlinked list, though these loops\ndon't surface because we immediately flush each unlinked inode after\nloading it.\n\nFix all of these issues.","publishedAt":"2026-10-18T15:14:53.597Z","updatedAt":"2026-10-30T12:38:08.950Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"8cfde7b2fb7288f4f6b90293e8702ff897c682fe","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"47a948ba653a463d429e02fda2f06a3d6b78666d","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"8c9d5b8a96d6b93eb24e07b4163c89341ba29bd1","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"66a2179d02668f8df44b1a249899006f3ba38ea0","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"961c717e6bf0e53c2c2b1fe4aef1add9390fedab","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"65f39d09d73718611cee40399179323b5d4ead00","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/xfs/xfs_log_recover.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.0","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.0","versionType":"semver"},{"version":"6.1.191","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.160","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.113","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.55","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.9","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/xfs/xfs_log_recover.c"]}],"references":["https://git.kernel.org/stable/c/8cfde7b2fb7288f4f6b90293e8702ff897c682fe","https://git.kernel.org/stable/c/47a948ba653a463d429e02fda2f06a3d6b78666d","https://git.kernel.org/stable/c/8c9d5b8a96d6b93eb24e07b4163c89341ba29bd1","https://git.kernel.org/stable/c/66a2179d02668f8df44b1a249899006f3ba38ea0","https://git.kernel.org/stable/c/961c717e6bf0e53c2c2b1fe4aef1add9390fedab","https://git.kernel.org/stable/c/65f39d09d73718611cee40399179323b5d4ead00"],"weaknesses":[],"ingestedAt":"2026-10-30T12:58:04.520Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/98xxx/CVE-2026-98443.json","commit":"1f312381e38164a43607eebab851b151dd16861e","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-98443","state":"PUBLISHED","datePublished":"2026-10-18T15:14:53.597Z","dateUpdated":"2026-10-30T12:38:08.950Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-09-25T10:25:14.349Z"},"containers":{"cna":{"title":"xfs: fix cursor and pointer handling when recovering iunlink buckets","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nxfs: fix cursor and pointer handling when recovering iunlink buckets\n\nLOLLM pointed out a bug in xlog_recover_iunlink_bucket:\n\n1. We don't null out prev_ip after releasing it, which can lead to UAF\n   problems if the inodegc flush call in the loop fails.\n\nat which point I noticed even more bugs:\n\n2. If the inodegc flush inside the loop fails, we also leak @ip.\n\n3. We set prev_agino to agino having already advanced agino, which\n   results in inodes with i_prev_unlinked set to itself.\n\n4. If we exit the bottom of the loop with prev_ip set, then prev_ip\n   aliases ip and we also set its i_prev_unlinked to itself.\n\nBugs 3 and 4 introduce loops into the unlinked list, though these loops\ndon't surface because we immediately flush each unlinked inode after\nloading it.\n\nFix all of these issues."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"8cfde7b2fb7288f4f6b90293e8702ff897c682fe","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"47a948ba653a463d429e02fda2f06a3d6b78666d","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"8c9d5b8a96d6b93eb24e07b4163c89341ba29bd1","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"66a2179d02668f8df44b1a249899006f3ba38ea0","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"961c717e6bf0e53c2c2b1fe4aef1add9390fedab","versionType":"git"},{"version":"04755d2e5821b3afbaadd09fe5df58d04de36484","status":"affected","lessThan":"65f39d09d73718611cee40399179323b5d4ead00","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/xfs/xfs_log_recover.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.0","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.0","versionType":"semver"},{"version":"6.1.191","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.160","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.113","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.55","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.2.9","status":"unaffected","lessThanOrEqual":"7.2.*","versionType":"semver"},{"version":"7.3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/xfs/xfs_log_recover.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/8cfde7b2fb7288f4f6b90293e8702ff897c682fe"},{"url":"https://git.kernel.org/stable/c/47a948ba653a463d429e02fda2f06a3d6b78666d"},{"url":"https://git.kernel.org/stable/c/8c9d5b8a96d6b93eb24e07b4163c89341ba29bd1"},{"url":"https://git.kernel.org/stable/c/66a2179d02668f8df44b1a249899006f3ba38ea0"},{"url":"https://git.kernel.org/stable/c/961c717e6bf0e53c2c2b1fe4aef1add9390fedab"},{"url":"https://git.kernel.org/stable/c/65f39d09d73718611cee40399179323b5d4ead00"}],"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 - Malformed agi_unlinked, di_next_unlinked, and inode-fork data enter from a local XFS image when mount(2) reaches xlog_recover_iunlink_bucket through xfs_log_mount_finish and xlog_recover_finish; no remote protocol carries these bytes.\nAC:L - The image author can create a dirty log, two inodes in one unlinked bucket, and corrupt external btree metadata that makes xfs_inactive fail through xfs_inodegc_flush. This deterministically enters the stale-prev_ip error path without requiring an uncontrollable hardware fault.\nPR:N - The attacker only creates and supplies the XFS image, requiring no target account or capability. XFS omits FS_USERNS_MOUNT, so the privileged mount_capable check applies to the interacting victim and is captured by UI:R.\nUI:R - A victim or administrator must mount the attacker-supplied dirty XFS image so xfs_log_mount_finish invokes xlog_recover_finish and the patched xlog_recover_iunlink_bucket.\nS:U - The stale xfs_inode and resulting memory corruption affect the mounting host kernel within its existing security authority; no VM, IOMMU, or other isolation boundary is crossed.\nC:H - After xfs_inodegc_flush makes prev_ip reclaimable, the stale pointer can reference an xfs_inode_cache object reclaimed and replaced before the second xfs_irele; reuse and secondary UAF of the replacement inode support kernel-memory disclosure.\nI:H - The second xfs_irele can decrement i_count in a reused xfs_inode, prematurely destroying a live replacement inode and producing secondary use-after-free memory corruption exploitable for control-flow hijacking.\nA:H - The stale xfs_irele can dereference a freed inode or underflow its reference count; DEBUG_VFS BUGs on the invalid inode state/count, while non-debug builds can corrupt a replacement inode and later oops or panic."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-10-30T12:38:08.950Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.1.191"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.6.160"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.12.113"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.18.55"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"7.2.9"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"7.3"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}