Skip to content
Heist/ feed
Unrated

usb: xhci: Fix NULL pointer dereference on certain command aborts

Type: advisorySource: Official CVE List1 source record

In the Linux kernel, the following vulnerability has been resolved: usb: xhci: Fix NULL pointer dereference on certain command aborts If a command is queued to the final usable TRB of a ring segment, the enqueue pointer is advanced to the subsequent link TRB and no further. If the command is later aborted, when the abort completion is handled the dequeue pointer is advanced to the first TRB of the next segment. If no further commands are queued, xhci_handle_stopped_cmd_ring() sees the ring pointers unequal and assumes that there is a pending command, so it calls xhci_mod_cmd_timer() which crashes if cur_cmd was NULL. Don't attempt timer setup if cur_cmd is NULL. The subsequent doorbell ring likely is unnecessary too, but it's harmless. Leave it alone. This is probably Bug 219532, but no confirmation has been received. The issue has been independently reproduced and confirmed fixed using a USB MCU programmed to NAK the Status stage of SET_ADDRESS forever. Everything continued working normally after several prevented crashes.

Announced Group revision 1
Original source ↗

CVE-2024-57981

Primary source · Revision 1

Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.

Security context

Source reference: cve:CVE-2024-57981

Linux

Source reference: /containers/cna/affected/0/product

Affected versions
Not stated in this record
Fixed versions
Not stated in this record
Prerequisites
Not stated in this record

Linux

Source reference: /containers/cna/affected/1/product

Affected versions
Not stated in this record
Fixed versions
Not stated in this record
Prerequisites
Not stated in this record

Structured affected-version data

Original package identities and version rules from this source.

[
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "fd8bfaeba4a85b14427899adec0efb3954300653",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "b44253956407046e5907d4d72c8fa5b93ae94485",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "cf30300a216a4f8dce94e11781a866a09d4b50d4",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "4ff18870af793ce2034a6ad746e91d0a3d985b88",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "b649f0d5bc256f691c7d234c3986685d54053de1",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "ae069cd2ba09a2bd6a87a68c59ef0b7ea39cd641",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "0ce5c0dac768be14afe2426101b568a0f66bfc4d",
        "versionType": "git"
      },
      {
        "status": "affected",
        "version": "c311e391a7efd101250c0e123286709b7e736249",
        "lessThan": "1e0a19912adb68a4b2b74fd77001c96cd83eb073",
        "versionType": "git"
      }
    ],
    "programFiles": [
      "drivers/usb/host/xhci-ring.c"
    ],
    "defaultStatus": "unaffected"
  },
  {
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "vendor": "Linux",
    "product": "Linux",
    "versions": [
      {
        "status": "affected",
        "version": "3.16"
      },
      {
        "status": "unaffected",
        "version": "0",
        "lessThan": "3.16",
        "versionType": "semver"
      },
      {
        "status": "unaffected",
        "version": "5.4.291",
        "versionType": "semver",
        "lessThanOrEqual": "5.4.*"
      },
      {
        "status": "unaffected",
        "version": "5.10.235",
        "versionType": "semver",
        "lessThanOrEqual": "5.10.*"
      },
      {
        "status": "unaffected",
        "version": "5.15.179",
        "versionType": "semver",
        "lessThanOrEqual": "5.15.*"
      },
      {
        "status": "unaffected",
        "version": "6.1.129",
        "versionType": "semver",
        "lessThanOrEqual": "6.1.*"
      },
      {
        "status": "unaffected",
        "version": "6.6.76",
        "versionType": "semver",
        "lessThanOrEqual": "6.6.*"
      },
      {
        "status": "unaffected",
        "version": "6.12.13",
        "versionType": "semver",
        "lessThanOrEqual": "6.12.*"
      },
      {
        "status": "unaffected",
        "version": "6.13.2",
        "versionType": "semver",
        "lessThanOrEqual": "6.13.*"
      },
      {
        "status": "unaffected",
        "version": "6.14",
        "versionType": "original_commit_for_fix",
        "lessThanOrEqual": "*"
      }
    ],
    "programFiles": [
      "drivers/usb/host/xhci-ring.c"
    ],
    "defaultStatus": "affected"
  }
]
Related CVEs
CVE-2024-57981

Source reference: /cveMetadata/cveId

Publisher severity

No explicit severity was provided.

Event
#26857 · Revision 1
Added to Heist Feed
Publisher date
Read the original announcement