# CVE-2025-21772: partitions: mac: fix handling of bogus partition table

- Severity: High 7.8 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.24%, higher than 16% of CVEs (2026-12-01)
- Published: 2025-02-27T02:18:19.528Z
- Modified: 2026-10-15T22:18:08.493Z
- Weaknesses: CWE-787
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact total
- Assigned by: Linux

## Description

In the Linux kernel, the following vulnerability has been resolved:

partitions: mac: fix handling of bogus partition table

Fix several issues in partition probing:

 - The bailout for a bad partoffset must use put_dev_sector(), since the
   preceding read_part_sector() succeeded.
 - If the partition table claims a silly sector size like 0xfff bytes
   (which results in partition table entries straddling sector boundaries),
   bail out instead of accessing out-of-bounds memory.
 - We must not assume that the partition table contains proper NUL
   termination - use strnlen() and strncmp() instead of strlen() and
   strcmp().

(As written by CVE List.)

## Affected

- Linux Linux: from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before a3e77da9f843e4ab93917d30c314f0283e28c124; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 213ba5bd81b7e97ac6e6190b8f3bc6ba76123625; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 40a35d14f3c0dc72b689061ec72fc9b193f37d1f; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 27a39d006f85e869be68c1d5d2ce05e5d6445bf5; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 92527100be38ede924768f4277450dfe8a40e16b; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 6578717ebca91678131d2b1f4ba4258e60536e9f; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 7fa9706722882f634090bfc9af642bf9ed719e27; from 02e2a5bfebe99edcf9d694575a75032d53fe1b73 before 80e648042e512d5a767da251d44132553fe04ae0; 81a319c5c29913a23947f3d28513974682f3af03; 34a906cd9f6445d9510841667eff0d980279ebf3; 2a27f61bd411e564eb4651c18d225f6e9e1de534; 69aad7e01c8e883e9d2f8dc5523bd419bd02d2aa; and 7 more (not affected: before 4.4; from 5.4.291 up to 5.4.*; from 5.10.235 up to 5.10.*; from 5.15.179 up to 5.15.*; from 6.1.129 up to 6.1.*; from 6.6.79 up to 6.6.*; from 6.12.16 up to 6.12.*; from 6.13.4 up to 6.13.*; from 6.14 up to *)
- linux linux_kernel: before 5.4.291; from 5.5 before 5.10.235; from 5.11 before 5.15.179; from 5.16 before 6.1.129; from 6.2 before 6.6.79; from 6.7 before 6.12.16; from 6.13 before 6.13.4; 6.14

## Every score

- Linux: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://git.kernel.org/stable/c/a3e77da9f843e4ab93917d30c314f0283e28c124> (patch)
- <https://git.kernel.org/stable/c/213ba5bd81b7e97ac6e6190b8f3bc6ba76123625> (patch)
- <https://git.kernel.org/stable/c/40a35d14f3c0dc72b689061ec72fc9b193f37d1f> (patch)
- <https://git.kernel.org/stable/c/27a39d006f85e869be68c1d5d2ce05e5d6445bf5> (patch)
- <https://git.kernel.org/stable/c/92527100be38ede924768f4277450dfe8a40e16b> (patch)
- <https://git.kernel.org/stable/c/6578717ebca91678131d2b1f4ba4258e60536e9f> (patch)
- <https://git.kernel.org/stable/c/7fa9706722882f634090bfc9af642bf9ed719e27> (patch)
- <https://git.kernel.org/stable/c/80e648042e512d5a767da251d44132553fe04ae0> (patch)
- <https://lists.debian.org/debian-lts-announce/2025/05/msg00030.html>
- <https://lists.debian.org/debian-lts-announce/2025/03/msg00028.html>
- <https://cert-portal.siemens.com/productcert/html/ssa-265688.html>

## Sources

- CVE List: [CVE-2025-21772](https://www.cve.org/CVERecord?id=CVE-2025-21772), CVE Terms of Use, modified 2026-10-15
- NVD: [CVE-2025-21772](https://nvd.nist.gov/vuln/detail/CVE-2025-21772), Public domain, modified 2026-10-15

---

Page: https://cve.day/CVE-2025-21772 · Whole record: https://cve.day/CVE-2025-21772.json · Rebuilt by cve.day 2026-11-25T22:58:54.552Z
