{"id":"CVE-2025-21874","state":"PUBLISHED","title":"dm-integrity: Avoid divide by zero in table status in Inline mode","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ndm-integrity: Avoid divide by zero in table status in Inline mode\n\nIn Inline mode, the journal is unused, and journal_sectors is zero.\n\nCalculating the journal watermark requires dividing by journal_sectors,\nwhich should be done only if the journal is configured.\n\nOtherwise, a simple table query (dmsetup table) can cause OOPS.\n\nThis bug did not show on some systems, perhaps only due to\ncompiler optimization.\n\nOn my 32-bit testing machine, this reliably crashes with the following:\n\n : Oops: divide error: 0000 [#1] PREEMPT SMP\n : CPU: 0 UID: 0 PID: 2450 Comm: dmsetup Not tainted 6.14.0-rc2+ #959\n : EIP: dm_integrity_status+0x2f8/0xab0 [dm_integrity]\n ...","publishedAt":"2025-03-27T14:57:05.496Z","updatedAt":"2026-05-11T21:08:11.622Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"22c6f577b3cb184857b440ae5e5916f6c9e7021d","versionType":"git"},{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"06d9895f265282e939a8933bb18de82eba2b4dda","versionType":"git"},{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"7fb39882b20c98a9a393c244c86b56ef6933cff8","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/md/dm-integrity.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.11","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.11","versionType":"semver"},{"version":"6.12.18","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.13.6","status":"unaffected","lessThanOrEqual":"6.13.*","versionType":"semver"},{"version":"6.14","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/md/dm-integrity.c"]}],"references":["https://git.kernel.org/stable/c/22c6f577b3cb184857b440ae5e5916f6c9e7021d","https://git.kernel.org/stable/c/06d9895f265282e939a8933bb18de82eba2b4dda","https://git.kernel.org/stable/c/7fb39882b20c98a9a393c244c86b56ef6933cff8"],"weaknesses":[],"ingestedAt":"2026-10-29T20:08:39.238Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/21xxx/CVE-2025-21874.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-21874","state":"PUBLISHED","datePublished":"2025-03-27T14:57:05.496Z","dateUpdated":"2026-05-11T21:08:11.622Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2024-12-29T08:45:45.781Z"},"containers":{"cna":{"title":"dm-integrity: Avoid divide by zero in table status in Inline mode","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ndm-integrity: Avoid divide by zero in table status in Inline mode\n\nIn Inline mode, the journal is unused, and journal_sectors is zero.\n\nCalculating the journal watermark requires dividing by journal_sectors,\nwhich should be done only if the journal is configured.\n\nOtherwise, a simple table query (dmsetup table) can cause OOPS.\n\nThis bug did not show on some systems, perhaps only due to\ncompiler optimization.\n\nOn my 32-bit testing machine, this reliably crashes with the following:\n\n : Oops: divide error: 0000 [#1] PREEMPT SMP\n : CPU: 0 UID: 0 PID: 2450 Comm: dmsetup Not tainted 6.14.0-rc2+ #959\n : EIP: dm_integrity_status+0x2f8/0xab0 [dm_integrity]\n ..."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"22c6f577b3cb184857b440ae5e5916f6c9e7021d","versionType":"git"},{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"06d9895f265282e939a8933bb18de82eba2b4dda","versionType":"git"},{"version":"fb0987682c629c1d2c476f35f6fde405a5e304a4","status":"affected","lessThan":"7fb39882b20c98a9a393c244c86b56ef6933cff8","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/md/dm-integrity.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.11","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.11","versionType":"semver"},{"version":"6.12.18","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.13.6","status":"unaffected","lessThanOrEqual":"6.13.*","versionType":"semver"},{"version":"6.14","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/md/dm-integrity.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/22c6f577b3cb184857b440ae5e5916f6c9e7021d"},{"url":"https://git.kernel.org/stable/c/06d9895f265282e939a8933bb18de82eba2b4dda"},{"url":"https://git.kernel.org/stable/c/7fb39882b20c98a9a393c244c86b56ef6933cff8"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T21:08:11.622Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.11","versionEndExcluding":"6.12.18"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.11","versionEndExcluding":"6.13.6"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.11","versionEndExcluding":"6.14"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}