{"id":"CVE-2026-74349","state":"PUBLISHED","title":"ocfs2: reject FITRIM ranges shorter than a cluster","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nocfs2: reject FITRIM ranges shorter than a cluster\n\nocfs2_trim_mainbm() trims the global bitmap in cluster units, but its\ntoo-short range validation only checks sb->s_blocksize.\n\nOn filesystems with a cluster size larger than the block size, a FITRIM\nrange that is at least one block but shorter than one cluster is accepted\nand shifted down to len == 0.  The later start + len - 1 and len -= ... \narithmetic then underflows and can drive trimming past the requested\nrange.\n\nReject ranges shorter than s_clustersize instead.  That preserves the\nexisting -EINVAL behavior for requests that cannot discard even one\nallocation unit and keeps zero-cluster trims out of the group walk.","publishedAt":"2026-08-15T05:58:36.630Z","updatedAt":"2026-10-16T18:55:34.720Z","severity":{"score":7.1,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"d903d59c0315f59bdf0214b4f13d71c9feb2c45c","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"441abb77222f155e8d931dbabb465466db01cfd7","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"e652d0f5108e447b22da4249bcd23dd1b63c73dd","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"346314bb0cc2fc52b50b73d6ecc62e0217455c2e","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"06c0a0431b9856506fcd9b2c1b0c6136567d756d","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"3fa7139b5f42731a61f78c42433adae13f9adc21","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"2c13e02592b918be7725ab5965e01ef4e46c4b57","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"ca1afd88f5eaaff9168e1466e5401385edf59543","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ocfs2/alloc.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"3.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"3.14","versionType":"semver"},{"version":"5.10.261","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.212","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.178","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.145","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.97","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.40","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.1.5","status":"unaffected","lessThanOrEqual":"7.1.*","versionType":"semver"},{"version":"7.2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ocfs2/alloc.c"]}],"references":["https://git.kernel.org/stable/c/d903d59c0315f59bdf0214b4f13d71c9feb2c45c","https://git.kernel.org/stable/c/441abb77222f155e8d931dbabb465466db01cfd7","https://git.kernel.org/stable/c/e652d0f5108e447b22da4249bcd23dd1b63c73dd","https://git.kernel.org/stable/c/346314bb0cc2fc52b50b73d6ecc62e0217455c2e","https://git.kernel.org/stable/c/06c0a0431b9856506fcd9b2c1b0c6136567d756d","https://git.kernel.org/stable/c/3fa7139b5f42731a61f78c42433adae13f9adc21","https://git.kernel.org/stable/c/2c13e02592b918be7725ab5965e01ef4e46c4b57","https://git.kernel.org/stable/c/ca1afd88f5eaaff9168e1466e5401385edf59543"],"weaknesses":[],"ingestedAt":"2026-10-29T20:12:58.252Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/74xxx/CVE-2026-74349.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-74349","state":"PUBLISHED","datePublished":"2026-08-15T05:58:36.630Z","dateUpdated":"2026-10-16T18:55:34.720Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-08-15T05:44:03.886Z"},"containers":{"cna":{"title":"ocfs2: reject FITRIM ranges shorter than a cluster","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nocfs2: reject FITRIM ranges shorter than a cluster\n\nocfs2_trim_mainbm() trims the global bitmap in cluster units, but its\ntoo-short range validation only checks sb->s_blocksize.\n\nOn filesystems with a cluster size larger than the block size, a FITRIM\nrange that is at least one block but shorter than one cluster is accepted\nand shifted down to len == 0.  The later start + len - 1 and len -= ... \narithmetic then underflows and can drive trimming past the requested\nrange.\n\nReject ranges shorter than s_clustersize instead.  That preserves the\nexisting -EINVAL behavior for requests that cannot discard even one\nallocation unit and keeps zero-cluster trims out of the group walk."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"d903d59c0315f59bdf0214b4f13d71c9feb2c45c","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"441abb77222f155e8d931dbabb465466db01cfd7","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"e652d0f5108e447b22da4249bcd23dd1b63c73dd","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"346314bb0cc2fc52b50b73d6ecc62e0217455c2e","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"06c0a0431b9856506fcd9b2c1b0c6136567d756d","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"3fa7139b5f42731a61f78c42433adae13f9adc21","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"2c13e02592b918be7725ab5965e01ef4e46c4b57","versionType":"git"},{"version":"aa89762c54800208d5afdcd8e6bf124818f17fe0","status":"affected","lessThan":"ca1afd88f5eaaff9168e1466e5401385edf59543","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ocfs2/alloc.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"3.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"3.14","versionType":"semver"},{"version":"5.10.261","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.212","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.1.178","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.6.145","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.12.97","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.40","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.1.5","status":"unaffected","lessThanOrEqual":"7.1.*","versionType":"semver"},{"version":"7.2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/ocfs2/alloc.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/d903d59c0315f59bdf0214b4f13d71c9feb2c45c"},{"url":"https://git.kernel.org/stable/c/441abb77222f155e8d931dbabb465466db01cfd7"},{"url":"https://git.kernel.org/stable/c/e652d0f5108e447b22da4249bcd23dd1b63c73dd"},{"url":"https://git.kernel.org/stable/c/346314bb0cc2fc52b50b73d6ecc62e0217455c2e"},{"url":"https://git.kernel.org/stable/c/06c0a0431b9856506fcd9b2c1b0c6136567d756d"},{"url":"https://git.kernel.org/stable/c/3fa7139b5f42731a61f78c42433adae13f9adc21"},{"url":"https://git.kernel.org/stable/c/2c13e02592b918be7725ab5965e01ef4e46c4b57"},{"url":"https://git.kernel.org/stable/c/ca1afd88f5eaaff9168e1466e5401385edf59543"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H","baseScore":7.1,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - Exploitation requires a local FITRIM ioctl on an open OCFS2 mount (typically via fstrim or ioctl on the mountpoint); there is no network-facing OCFS2 handler or remote protocol path to this code.\nAC:L - An attacker with the required privileges can reliably trigger the bug by supplying a FITRIM range at least one block long but shorter than one cluster, which is common when OCFS2 cluster size exceeds the 4K block size.\nPR:L - The FITRIM handler explicitly requires capable(CAP_SYS_ADMIN) before calling ocfs2_trim_fs(); per kernel CNA guidance this maps to Low because CAP_SYS_ADMIN can be held by root inside a user namespace.\nUI:N - No victim interaction is required; the privileged attacker directly issues the FITRIM ioctl with crafted range parameters to trigger the faulty trim logic.\nS:U - Impact is confined to erroneous discard/trim operations within the same privileged filesystem context on the affected host and shared storage; it does not cross VM, container, or IOMMU security boundaries.\nC:N - The flaw causes incorrect discard of free clusters via sb_issue_discard and integer underflow in range arithmetic; it does not read kernel memory, leak pointers, or expose sensitive data to the attacker.\nI:H - Unsigned underflow can drive trimming far beyond the requested FITRIM range, issuing discard on extensive free-space regions on shared cluster storage and risking unintended loss or corruption of filesystem data integrity.\nA:H - Corrupted len/last_group values can cause prolonged iteration through cluster groups while holding the exclusive OCFS2 cluster-wide trim DLM lock, enabling severe denial of service or hang for the node and other cluster members."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-17T05:46:12.774Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"5.10.261"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"5.15.212"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"6.1.178"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"6.6.145"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"6.12.97"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"6.18.40"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"7.1.5"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"3.14","versionEndExcluding":"7.2"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"id":"CVE-2026-74349","role":"CISA Coordinator","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"version":"2.0.3","timestamp":"2026-10-16T18:54:14.069402Z"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-10-16T18:55:34.720Z"}}]}}}