CVE-2024-42235 (GCVE-0-2024-42235)
Vulnerability from cvelistv5
Published
2024-08-07 15:14
Modified
2026-08-05 11:36
Summary
In the Linux kernel, the following vulnerability has been resolved: s390/mm: Add NULL pointer check to crst_table_free() base_crst_free() crst_table_free() used to work with NULL pointers before the conversion to ptdescs. Since crst_table_free() can be called with a NULL pointer (error handling in crst_table_upgrade() add an explicit check. Also add the same check to base_crst_free() for consistency reasons. In real life this should not happen, since order two GFP_KERNEL allocations will not fail, unless FAIL_PAGE_ALLOC is enabled and used.
Impacted products
Vendor Product Version
Linux Linux Version: 6326c26c1514757242829b292b26eac589013200
Version: 6326c26c1514757242829b292b26eac589013200
Version: 6326c26c1514757242829b292b26eac589013200
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2024-42235",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-09-10T16:14:07.518719Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-09-11T17:34:32.266Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "arch/s390/mm/pgalloc.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "794fa52b94637d6b2e8c9474fbe3983af5c9f046",
              "status": "affected",
              "version": "6326c26c1514757242829b292b26eac589013200",
              "versionType": "git"
            },
            {
              "lessThan": "f80bd8bb6f380bc265834c46058d38b34174813e",
              "status": "affected",
              "version": "6326c26c1514757242829b292b26eac589013200",
              "versionType": "git"
            },
            {
              "lessThan": "b5efb63acf7bddaf20eacfcac654c25c446eabe8",
              "status": "affected",
              "version": "6326c26c1514757242829b292b26eac589013200",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "arch/s390/mm/pgalloc.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.6"
            },
            {
              "lessThan": "6.6",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.41",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.9.*",
              "status": "unaffected",
              "version": "6.9.10",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.10",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.41",
                  "versionStartIncluding": "6.6",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.9.10",
                  "versionStartIncluding": "6.6",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.10",
                  "versionStartIncluding": "6.6",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\ns390/mm: Add NULL pointer check to crst_table_free() base_crst_free()\n\ncrst_table_free() used to work with NULL pointers before the conversion\nto ptdescs.  Since crst_table_free() can be called with a NULL pointer\n(error handling in crst_table_upgrade() add an explicit check.\n\nAlso add the same check to base_crst_free() for consistency reasons.\n\nIn real life this should not happen, since order two GFP_KERNEL\nallocations will not fail, unless FAIL_PAGE_ALLOC is enabled and used."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7.8,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:L - The vulnerable path is entered only through a local `mmap()`/`mremap()`/`shmat()` syscall on s390, via `arch_get_unmapped_area()` \u2192 `check_asce_limit()` \u2192 `crst_table_upgrade()`. No network, adjacent-network, or remote-peer data reaches this code.\nAC:L - The attacker fully controls the address-space geometry needed (two ordinary high-address mmaps drive `asce_limit` to `_REGION1_SIZE` and then request a 5-level upgrade, leaving `p4d == NULL`), and can engineer the required order-2 `GFP_KERNEL` failure by driving their own multithreaded process into the OOM-victim state that makes `__alloc_pages_slowpath()` return NULL, retrying as often as needed. Every attempt is cheap and repeatable, so the remaining timing window is one the attacker creates rather than one beyond their control.\nPR:L - Any unprivileged local user can call `mmap()` with a high address hint \u2014 there is no capability check, namespace requirement, or privileged device node anywhere between the syscall entry and `crst_table_free()`. On IBM Z / LinuxONE hosts this means any shared-tenant, container, or shell user.\nUI:N - The whole sequence is performed by the attacking process itself through ordinary syscalls; no victim must mount a filesystem, open a device, or take any other action.\nS:U - The corrupted page-allocator state and the freed reserved page remain entirely within the kernel\u0027s own security authority; no VM, IOMMU, or sandbox boundary is crossed.\nC:H - On 6.6.y the reserved PFN 0 (the s390 absolute-zero lowcore holding restart PSWs and `restart_fn`/`restart_data` kernel pointers plus machine-check save areas) is released into the buddy allocator with the sanity checks compiled out, so it can be handed to an attacker-influenced allocation still containing that firmware/kernel state; repeating the trigger underflows the refcount of whatever page then occupies PFN 0, yielding a use-after-free read primitive over live kernel memory.\nI:H - Injecting a memblock-reserved page into the buddy free lists breaks the allocator\u0027s ownership invariant \u2014 the page is concurrently written by hardware/firmware (store status, machine-check save area) while owned by another kernel object or user mapping \u2014 and the refcount underflow on repeat triggers gives a double-free/page-reuse primitive, the classic route to controlled kernel writes.\nA:H - On 6.9/6.10 the underflowed `__pa(0)` produces a wild `struct page *` that faults in `compound_order()`, oopsing the kernel; on 6.6.y with page-checking enabled it produces a \"BUG: Bad page state\" splat and `TAINT_BAD_PAGE` (a panic under `panic_on_taint`), and with checks off the corrupted allocator state leads to subsequent oops/panic."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T11:36:00.433Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/794fa52b94637d6b2e8c9474fbe3983af5c9f046"
        },
        {
          "url": "https://git.kernel.org/stable/c/f80bd8bb6f380bc265834c46058d38b34174813e"
        },
        {
          "url": "https://git.kernel.org/stable/c/b5efb63acf7bddaf20eacfcac654c25c446eabe8"
        }
      ],
      "title": "s390/mm: Add NULL pointer check to crst_table_free() base_crst_free()",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2024-42235",
    "datePublished": "2024-08-07T15:14:25.070Z",
    "dateReserved": "2024-07-30T07:40:12.252Z",
    "dateUpdated": "2026-08-05T11:36:00.433Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "vulnrichment": {
      "containers": "{\"adp\": [{\"title\": \"CISA ADP Vulnrichment\", \"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2024-42235\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2024-09-10T16:14:07.518719Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2024-09-11T12:42:24.295Z\"}}], \"cna\": {\"title\": \"s390/mm: Add NULL pointer check to crst_table_free() base_crst_free()\", \"affected\": [{\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"6326c26c1514757242829b292b26eac589013200\", \"lessThan\": \"794fa52b94637d6b2e8c9474fbe3983af5c9f046\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"6326c26c1514757242829b292b26eac589013200\", \"lessThan\": \"f80bd8bb6f380bc265834c46058d38b34174813e\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"6326c26c1514757242829b292b26eac589013200\", \"lessThan\": \"b5efb63acf7bddaf20eacfcac654c25c446eabe8\", \"versionType\": \"git\"}], \"programFiles\": [\"arch/s390/mm/pgalloc.c\"], \"defaultStatus\": \"unaffected\"}, {\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"6.6\"}, {\"status\": \"unaffected\", \"version\": \"0\", \"lessThan\": \"6.6\", \"versionType\": \"semver\"}, {\"status\": \"unaffected\", \"version\": \"6.6.41\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.6.*\"}, {\"status\": \"unaffected\", \"version\": \"6.9.10\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"6.9.*\"}, {\"status\": \"unaffected\", \"version\": \"6.10\", \"versionType\": \"original_commit_for_fix\", \"lessThanOrEqual\": \"*\"}], \"programFiles\": [\"arch/s390/mm/pgalloc.c\"], \"defaultStatus\": \"affected\"}], \"references\": [{\"url\": \"https://git.kernel.org/stable/c/794fa52b94637d6b2e8c9474fbe3983af5c9f046\"}, {\"url\": \"https://git.kernel.org/stable/c/f80bd8bb6f380bc265834c46058d38b34174813e\"}, {\"url\": \"https://git.kernel.org/stable/c/b5efb63acf7bddaf20eacfcac654c25c446eabe8\"}], \"x_generator\": {\"engine\": \"bippy-1.2.0\"}, \"descriptions\": [{\"lang\": \"en\", \"value\": \"In the Linux kernel, the following vulnerability has been resolved:\\n\\ns390/mm: Add NULL pointer check to crst_table_free() base_crst_free()\\n\\ncrst_table_free() used to work with NULL pointers before the conversion\\nto ptdescs.  Since crst_table_free() can be called with a NULL pointer\\n(error handling in crst_table_upgrade() add an explicit check.\\n\\nAlso add the same check to base_crst_free() for consistency reasons.\\n\\nIn real life this should not happen, since order two GFP_KERNEL\\nallocations will not fail, unless FAIL_PAGE_ALLOC is enabled and used.\"}], \"cpeApplicability\": [{\"nodes\": [{\"negate\": false, \"cpeMatch\": [{\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"6.6.41\", \"versionStartIncluding\": \"6.6\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"6.9.10\", \"versionStartIncluding\": \"6.6\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"6.10\", \"versionStartIncluding\": \"6.6\"}], \"operator\": \"OR\"}]}], \"providerMetadata\": {\"orgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"shortName\": \"Linux\", \"dateUpdated\": \"2025-05-04T09:24:45.510Z\"}}}",
      "cveMetadata": "{\"cveId\": \"CVE-2024-42235\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2025-05-04T09:24:45.510Z\", \"dateReserved\": \"2024-07-30T07:40:12.252Z\", \"assignerOrgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"datePublished\": \"2024-08-07T15:14:25.070Z\", \"assignerShortName\": \"Linux\"}",
      "dataType": "CVE_RECORD",
      "dataVersion": "5.1"
    }
  }
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…