Lucene search

K
cvelistLinuxCVELIST:CVE-2024-42244
HistoryAug 07, 2024 - 3:14 p.m.

CVE-2024-42244 USB: serial: mos7840: fix crash on resume

2024-08-0715:14:30
Linux
www.cve.org
6
usb
serial
mos7840
fix
crash
resume
linux kernel
vulnerability
commit
generic
method
driver
urbs
delock 87414
adapter

EPSS

0

Percentile

5.0%

In the Linux kernel, the following vulnerability has been resolved:

USB: serial: mos7840: fix crash on resume

Since commit c49cfa917025 (“USB: serial: use generic method if no
alternative is provided in usb serial layer”), USB serial core calls the
generic resume implementation when the driver has not provided one.

This can trigger a crash on resume with mos7840 since support for
multiple read URBs was added back in 2011. Specifically, both port read
URBs are now submitted on resume for open ports, but the context pointer
of the second URB is left set to the core rather than mos7840 port
structure.

Fix this by implementing dedicated suspend and resume functions for
mos7840.

Tested with Delock 87414 USB 2.0 to 4x serial adapter.

[ johan: analyse crash and rewrite commit message; set busy flag on
resume; drop bulk-in check; drop unnecessary usb_kill_urb() ]

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/usb/serial/mos7840.c"
    ],
    "versions": [
      {
        "version": "d83b405383c9",
        "lessThan": "932a86a711c7",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "d83b405383c9",
        "lessThan": "b14aa5673e0a",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "d83b405383c9",
        "lessThan": "1094ed500987",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "d83b405383c9",
        "lessThan": "5ae6a64f1821",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "d83b405383c9",
        "lessThan": "553e67dec846",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "d83b405383c9",
        "lessThan": "c15a688e4998",
        "status": "affected",
        "versionType": "git"
      }
    ]
  },
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "affected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/usb/serial/mos7840.c"
    ],
    "versions": [
      {
        "version": "3.3",
        "status": "affected"
      },
      {
        "version": "0",
        "lessThan": "3.3",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.10.222",
        "lessThanOrEqual": "5.10.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "5.15.163",
        "lessThanOrEqual": "5.15.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.1.100",
        "lessThanOrEqual": "6.1.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.6.41",
        "lessThanOrEqual": "6.6.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.9.10",
        "lessThanOrEqual": "6.9.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.10",
        "lessThanOrEqual": "*",
        "status": "unaffected",
        "versionType": "original_commit_for_fix"
      }
    ]
  }
]