# CVE-2025-22036: exfat: fix random stack corruption after get\_block

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.22% (percentile 8, 2026-11-26)
- **CWE:** CWE-362, CWE-416
- **Published:** 2025-04-16T14:11:54.916Z
- **Modified:** 2026-08-05T11:56:08.974Z

## Who should check

- Anyone running Linux \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f7447286363dc1e410bf30b87d75168f3519f9cc; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f807a6bf2005740fa26b4f59c4a003dc966b9afd; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca
- Anyone running Linux 6.8

## Description

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

exfat: fix random stack corruption after get\_block

When get\_block is called with a buffer\_head allocated on the stack, such
as do\_mpage\_readpage, stack corruption due to buffer\_head UAF may occur in
the following race condition situation.

     \<CPU 0\>                      \<CPU 1\>
mpage\_read\_folio
  \<\<bh on stack\>\>
  do\_mpage\_readpage
    exfat\_get\_block
      bh\_read
        \_\_bh\_read
	  get\_bh(bh)
          submit\_bh
          wait\_on\_buffer
                              ...
                              end\_buffer\_read\_sync
                                \_\_end\_buffer\_read\_notouch
                                   unlock\_buffer
          \<\<keep going\>\>
        ...
      ...
    ...
  ...
\<\<bh is not valid out of mpage\_read\_folio\>\>
   .
   .
another\_function
  \<\<variable A on stack\>\>
                                   put\_bh(bh)
                                     atomic\_dec(bh-\>b\_count)
  \* stack corruption here \*

This patch returns -EAGAIN if a folio does not have buffers when bh\_read
needs to be called. By doing this, the caller can fallback to functions
like block\_read\_full\_folio(), create a buffer\_head in the folio, and then
call get\_block again.

Let's do not call bh\_read() with on-stack buffer\_head.

## Affected and fixed versions

- Linux: \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f7447286363dc1e410bf30b87d75168f3519f9cc; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f807a6bf2005740fa26b4f59c4a003dc966b9afd; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca (cvelist)
- Linux: 6.8 (cvelist)

## Mitigation

- Upgrade Linux to 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-22036. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-22036.md
Affected: Linux >= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, < 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2; >= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, < f7447286363dc1e410bf30b87d75168f3519f9cc; >= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, < f807a6bf2005740fa26b4f59c4a003dc966b9afd; >= 11a347fb6cef62ce47e84b9…
Fixed in: Linux 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2, Linux 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-22036 being exploited?

There is no confirmed exploitation: CVE-2025-22036 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.22% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-22036?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-22036?

Linux \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f7447286363dc1e410bf30b87d75168f3519f9cc; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< f807a6bf2005740fa26b4f59c4a003dc966b9afd; \>= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \< 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca; Linux 6.8.

### Is there a fix for CVE-2025-22036?

Yes. Fixed in Linux 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2, Linux 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca. Upgrade Linux to 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca or later.

### How do I check if I'm affected by CVE-2025-22036?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2>
- patch: <https://git.kernel.org/stable/c/f7447286363dc1e410bf30b87d75168f3519f9cc>
- patch: <https://git.kernel.org/stable/c/f807a6bf2005740fa26b4f59c4a003dc966b9afd>
- patch: <https://git.kernel.org/stable/c/1bb7ff4204b6d4927e982cd256286c09ed4fd8ca>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-22036>

HTML: <https://flawdb.com/CVE-2025-22036> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-22036>
