CVE-2026-139723

scsi: mpi3mr: Fix buffer overflow in the BSG target device map

Published Nov 30, 2026 CVSS n/a EPSS n/a KEV · Not listed
Description
In the Linux kernel, the following vulnerability has been resolved:

scsi: mpi3mr: Fix buffer overflow in the BSG target device map

The size of the target device map buffer is held in a u16 while the number
of devices it is derived from is not bounded to fit. With enough devices
the size wraps, a short buffer is allocated, and the loop that fills it
writes past the end.

Do the calculation in size_t.

Analysis

AI-generated

Technical impact

A buffer overflow was identified in the Linux MPI3SCSI driver (mpi3mr). The driver allocates a target device map buffer using a u16 value for its size. When a connection contains many devices, the u16 can overflow, causing a short buffer to be allocated. A subsequent loop then writes past the end of this buffer, corrupting kernel memory. The overflow occurs in kernel space and can be triggered by presenting a SCSI target with an unbounded number of devices. Based on the description, it is inferred that an attacker could deliver controlling target devices to trigger the overflow and potentially execute arbitrary code with kernel privileges.

Affected Systems

Affected systems are all Linux kernel installations that include the mpi3mr driver before the fixes are applied. Vendor data lists only “Linux: Linux”, so affected products are general-purpose Linux kernels. No specific version ranges are provided; the key commits that contain the patch are shown in the reference URLs.

Risk and Exploitability

The bug is a classic integer overflow leading to a buffer overflow, a high-impact kernel memory corruption. The CVSS score is not listed, but such bugs routinely receive top-end scores (close to 9–10). The EPSS score is not available, and the issue is not listed in CISA’s KEV catalog, suggesting no known active exploitation yet. However, because the vulnerability is in kernel code and can be triggered by a malicious SCSI target, it should be considered a serious security risk.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update the Linux kernel to a version that includes the commit fixing size calculations in mpi3mr (see the provided commit URLs).
  • Restrict the maximum number of SCSI target devices presented to the mpi3mr driver to a safe value to avoid overflow. This may involve configuring the SCSI target firmware or BIOS to limit device count.
  • If the driver is unnecessary for your environment, disable the mpi3mr module in the kernel configuration.

Generated by OpenCVE AI on December 1, 2026 at 02:01 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Weaknesses CWE-119
CWE-680
Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: scsi: mpi3mr: Fix buffer overflow in the BSG target device map The size of the target device map buffer is held in a u16 while the number of devices it is derived from is not bounded to fit. With enough devices the size wraps, a short buffer is allocated, and the loop that fills it writes past the end. Do the calculation in size_t.
Title scsi: mpi3mr: Fix buffer overflow in the BSG target device map
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References
Weaknesses
  • CWE-119

    Improper Restriction of Operations within the Bounds of a Memory Buffer

  • CWE-680

    Integer Overflow to Buffer Overflow

Sources

Status
PUBLISHED
Assigner
Linux
Published
Updated
Nov 30, 2026, 1:37 PM
Reserved
Nov 30, 2026, 1:22 PM
Status
Received
Published
Nov 30, 2026, 2:20 PM
Modified
Nov 30, 2026, 2:20 PM