{
  "id": "CVE-2025-40241",
  "url": "https://poc.griffinguard.io/cve/CVE-2025-40241",
  "published_at": "2025-12-04T15:31:30.594Z",
  "title": "erofs: fix crafted invalid cases for encoded extents",
  "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\nerofs: fix crafted invalid cases for encoded extents\n\nRobert recently reported two corrupted images that can cause system\ncrashes, which are related to the new encoded extents introduced\nin Linux 6.15:\n\n  - The first one [1] has plen != 0 (e.g. plen == 0x2000000) but\n    (plen \u0026 Z_EROFS_EXTENT_PLEN_MASK) == 0. It is used to represent\n    special extents such as sparse extents (!EROFS_MAP_MAPPED), but\n    previously only plen == 0 was handled;\n\n  - The second one [2] has pa 0xffffffffffdcffed and plen 0xb4000,\n    then \"cur [0xfffffffffffff000] += bvec.bv_len [0x1000]\" in\n    \"} while ((cur += bvec.bv_len) \u003c end);\" wraps around, causing an\n    out-of-bound access of pcl-\u003ecompressed_bvecs[] in\n    z_erofs_submit_queue().  EROFS only supports 48-bit physical block\n    addresses (up to 1EiB for 4k blocks), so add a sanity check to\n    enforce this.",
  "cvss_by_source": {
    "cna": 7.8
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "\u003e= 1d191b4ca51d73699cb127386b95ac152af2b930, \u003c 00d8fe0b72f4ca0a983abced36aad2160038c421",
          "\u003e= 1d191b4ca51d73699cb127386b95ac152af2b930, \u003c a429b76114aaca3ef1aff4cd469dcf025431bd11"
        ],
        "fixed_in": [
          "00d8fe0b72f4ca0a983abced36aad2160038c421",
          "a429b76114aaca3ef1aff4cd469dcf025431bd11"
        ]
      },
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "6.15"
        ],
        "fixed_in": [
          "0",
          "6.17.6",
          "6.18"
        ]
      }
    ],
    "upgrade": [
      "Upgrade Linux to 00d8fe0b72f4ca0a983abced36aad2160038c421 or a429b76114aaca3ef1aff4cd469dcf025431bd11 or later.",
      "Upgrade Linux to 0 or 6.17.6 or 6.18 or later."
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
