CVE-2025-37801 (GCVE-0-2025-37801)
Vulnerability from cvelistv5
Published
2025-05-08 06:26
Modified
2026-08-05 11:57
Summary
In the Linux kernel, the following vulnerability has been resolved: spi: spi-imx: Add check for spi_imx_setupxfer() Add check for the return value of spi_imx_setupxfer(). spi_imx->rx and spi_imx->tx function pointer can be NULL when spi_imx_setupxfer() return error, and make NULL pointer dereference. Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000 Call trace: 0x0 spi_imx_pio_transfer+0x50/0xd8 spi_imx_transfer_one+0x18c/0x858 spi_transfer_one_message+0x43c/0x790 __spi_pump_transfer_message+0x238/0x5d4 __spi_sync+0x2b0/0x454 spi_write_then_read+0x11c/0x200
Impacted products
Vendor Product Version
Linux Linux Version: 307c897db762d1e0feee9477276b08f6deca4a5b
Version: 307c897db762d1e0feee9477276b08f6deca4a5b
Version: 307c897db762d1e0feee9477276b08f6deca4a5b
Version: 307c897db762d1e0feee9477276b08f6deca4a5b
Version: 307c897db762d1e0feee9477276b08f6deca4a5b
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "adp": [
      {
        "providerMetadata": {
          "dateUpdated": "2025-11-03T19:55:31.277Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "url": "https://lists.debian.org/debian-lts-announce/2025/05/msg00045.html"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/spi/spi-imx.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "2fea0d6d7b5d27fbf55512d51851ba0a346ede52",
              "status": "affected",
              "version": "307c897db762d1e0feee9477276b08f6deca4a5b",
              "versionType": "git"
            },
            {
              "lessThan": "2b4479eb462ecb39001b38dfb331fc6028dedac8",
              "status": "affected",
              "version": "307c897db762d1e0feee9477276b08f6deca4a5b",
              "versionType": "git"
            },
            {
              "lessThan": "185d376875ea6fb4256b9dc97ee0b4d2b0fdd399",
              "status": "affected",
              "version": "307c897db762d1e0feee9477276b08f6deca4a5b",
              "versionType": "git"
            },
            {
              "lessThan": "055ef73bb1afc3f783a9a13b496770a781964a07",
              "status": "affected",
              "version": "307c897db762d1e0feee9477276b08f6deca4a5b",
              "versionType": "git"
            },
            {
              "lessThan": "951a04ab3a2db4029debfa48d380ef834b93207e",
              "status": "affected",
              "version": "307c897db762d1e0feee9477276b08f6deca4a5b",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/spi/spi-imx.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.19"
            },
            {
              "lessThan": "5.19",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.1.*",
              "status": "unaffected",
              "version": "6.1.136",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.89",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.26",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.14.*",
              "status": "unaffected",
              "version": "6.14.5",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "6.15",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1.136",
                  "versionStartIncluding": "5.19",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.89",
                  "versionStartIncluding": "5.19",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.26",
                  "versionStartIncluding": "5.19",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.14.5",
                  "versionStartIncluding": "5.19",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.15",
                  "versionStartIncluding": "5.19",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nspi: spi-imx: Add check for spi_imx_setupxfer()\n\nAdd check for the return value of spi_imx_setupxfer().\nspi_imx-\u003erx and spi_imx-\u003etx function pointer can be NULL when\nspi_imx_setupxfer() return error, and make NULL pointer dereference.\n\n Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000\n Call trace:\n  0x0\n  spi_imx_pio_transfer+0x50/0xd8\n  spi_imx_transfer_one+0x18c/0x858\n  spi_transfer_one_message+0x43c/0x790\n  __spi_pump_transfer_message+0x238/0x5d4\n  __spi_sync+0x2b0/0x454\n  spi_write_then_read+0x11c/0x200"
        }
      ],
      "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 reached from a local process issuing write()/read()/SPI_IOC_MESSAGE on /dev/spidevB.C, or from an in-kernel SPI protocol driver via spi_write_then_read(); there is no network or remote-peer input involved.\nAC:L - On an affected board (an i.MX SPI slave node lacking spi-max-frequency, which spi-imx never compensates for since it sets no controller-\u003emax_speed_hz) every transfer without an explicit speed deterministically takes the unchecked error path \u2014 no race, no memory-layout luck, and the attacker fully controls transfer speed_hz, bits_per_word, len and word_delay through a single ioctl.\nPR:L - An ordinary unprivileged local user with access to the spidev character device (routinely granted via an \"spi\" group on embedded/industrial i.MX deployments) can submit the crafted spi_ioc_transfer array; no CAP_SYS_ADMIN or root is needed.\nUI:N - The attacker performs the ioctl/write themselves; no action by another user or administrator is required.\nS:U - The corruption and crash are confined to the kernel of the same system; no VM, IOMMU, or other security-authority boundary is crossed.\nC:H - The stale spi_imx-\u003etx/bits_per_word state left by the unchecked error causes spi_imx-\u003ecount to underflow, so spi_imx_buf_tx_u32() reads far past the transfer\u0027s TX buffer and shifts adjacent kernel heap memory out onto the SPI bus, where an attacker-controlled or observable peripheral can read it.\nI:H - The same count underflow makes spi_imx_buf_rx_u32() write 4 bytes per FIFO word past the end of the RX buffer, repeatedly from spi_imx_isr(), giving an unbounded heap out-of-bounds write with data sourced from the SPI RX FIFO.\nA:H - In the common case spi_imx-\u003etx is NULL and spi_imx_push() jumps to address 0, producing a kernel NULL pointer dereference oops/panic exactly as shown in the fix\u0027s backtrace; the OOB-write variant likewise corrupts the heap and crashes the system."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-08-05T11:57:40.320Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/2fea0d6d7b5d27fbf55512d51851ba0a346ede52"
        },
        {
          "url": "https://git.kernel.org/stable/c/2b4479eb462ecb39001b38dfb331fc6028dedac8"
        },
        {
          "url": "https://git.kernel.org/stable/c/185d376875ea6fb4256b9dc97ee0b4d2b0fdd399"
        },
        {
          "url": "https://git.kernel.org/stable/c/055ef73bb1afc3f783a9a13b496770a781964a07"
        },
        {
          "url": "https://git.kernel.org/stable/c/951a04ab3a2db4029debfa48d380ef834b93207e"
        }
      ],
      "title": "spi: spi-imx: Add check for spi_imx_setupxfer()",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2025-37801",
    "datePublished": "2025-05-08T06:26:01.980Z",
    "dateReserved": "2025-04-16T04:51:23.941Z",
    "dateUpdated": "2026-08-05T11:57:40.320Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2"
}


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…