{
  "id": "CVE-2025-22036",
  "url": "https://poc.griffinguard.io/cve/CVE-2025-22036",
  "published_at": "2025-04-16T14:11:54.916Z",
  "title": "exfat: fix random stack corruption after get_block",
  "vendor": "Linux",
  "product": "Linux",
  "cvss": {
    "score": 7.8,
    "source": "cna",
    "vector": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
  },
  "kev": {
    "in_kev": false,
    "added_at": null,
    "days_after_publication": null
  },
  "first_poc": null,
  "poc_repo_count": 0,
  "exploit_count": 0,
  "suspicious_repo_count": 0,
  "edge_device": null,
  "description": "In the Linux kernel, the following vulnerability has been resolved:\n\nexfat: fix random stack corruption after get_block\n\nWhen get_block is called with a buffer_head allocated on the stack, such\nas do_mpage_readpage, stack corruption due to buffer_head UAF may occur in\nthe following race condition situation.\n\n     \u003cCPU 0\u003e                      \u003cCPU 1\u003e\nmpage_read_folio\n  \u003c\u003cbh on stack\u003e\u003e\n  do_mpage_readpage\n    exfat_get_block\n      bh_read\n        __bh_read\n\t  get_bh(bh)\n          submit_bh\n          wait_on_buffer\n                              ...\n                              end_buffer_read_sync\n                                __end_buffer_read_notouch\n                                   unlock_buffer\n          \u003c\u003ckeep going\u003e\u003e\n        ...\n      ...\n    ...\n  ...\n\u003c\u003cbh is not valid out of mpage_read_folio\u003e\u003e\n   .\n   .\nanother_function\n  \u003c\u003cvariable A on stack\u003e\u003e\n                                   put_bh(bh)\n                                     atomic_dec(bh-\u003eb_count)\n  * stack corruption here *\n\nThis patch returns -EAGAIN if a folio does not have buffers when bh_read\nneeds to be called. By doing this, the caller can fallback to functions\nlike block_read_full_folio(), create a buffer_head in the folio, and then\ncall get_block again.\n\nLet's do not call bh_read() with on-stack buffer_head.",
  "cwe": "CWE-416",
  "cpes": [
    "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*"
  ],
  "cvss_by_source": {
    "cisa-adp": 7,
    "cna": 7.8,
    "nvd": 7
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "\u003e= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \u003c 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2",
          "\u003e= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \u003c f7447286363dc1e410bf30b87d75168f3519f9cc",
          "\u003e= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \u003c f807a6bf2005740fa26b4f59c4a003dc966b9afd",
          "\u003e= 11a347fb6cef62ce47e84b97c45f2b2497c7593b, \u003c 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca"
        ],
        "fixed_in": [
          "49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2",
          "f7447286363dc1e410bf30b87d75168f3519f9cc",
          "f807a6bf2005740fa26b4f59c4a003dc966b9afd",
          "1bb7ff4204b6d4927e982cd256286c09ed4fd8ca"
        ]
      },
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "6.8"
        ],
        "fixed_in": [
          "0",
          "6.12.23",
          "6.13.11",
          "6.14.2",
          "6.15"
        ]
      }
    ],
    "upgrade": [
      "Upgrade Linux to 49b0a6ab8e528a0c1c50e37cef9b9c7c121365f2 or f7447286363dc1e410bf30b87d75168f3519f9cc or f807a6bf2005740fa26b4f59c4a003dc966b9afd or 1bb7ff4204b6d4927e982cd256286c09ed4fd8ca or later.",
      "Upgrade Linux to 0 or 6.12.23 or 6.13.11 or 6.14.2 or 6.15 or later."
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
