Lucene search

K
vulnrichmentLinuxVULNRICHMENT:CVE-2024-35843
HistoryMay 17, 2024 - 2:40 p.m.

CVE-2024-35843 iommu/vt-d: Use device rbtree in iopf reporting path

2024-05-1714:40:10
Linux
github.com
1
linux kernel
iommu/vt-d
device rbtree
iopf reporting path
pci device
synchronization
mutex
use-after-free
vulnerability
cve-2024-35843

6.8 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

9.0%

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

iommu/vt-d: Use device rbtree in iopf reporting path

The existing I/O page fault handler currently locates the PCI device by
calling pci_get_domain_bus_and_slot(). This function searches the list
of all PCI devices until the desired device is found. To improve lookup
efficiency, replace it with device_rbtree_find() to search the device
within the probed device rbtree.

The I/O page fault is initiated by the device, which does not have any
synchronization mechanism with the software to ensure that the device
stays in the probed device tree. Theoretically, a device could be released
by the IOMMU subsystem after device_rbtree_find() and before
iopf_get_dev_fault_param(), which would cause a use-after-free problem.

Add a mutex to synchronize the I/O page fault reporting path and the IOMMU
release device path. This lock doesn’t introduce any performance overhead,
as the conflict between I/O page fault reporting and device releasing is
very rare.

CNA Affected

[
  {
    "product": "Linux",
    "vendor": "Linux",
    "defaultStatus": "unaffected",
    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
    "programFiles": [
      "drivers/iommu/intel/dmar.c",
      "drivers/iommu/intel/iommu.c",
      "drivers/iommu/intel/iommu.h",
      "drivers/iommu/intel/svm.c"
    ],
    "versions": [
      {
        "version": "1da177e4c3f4",
        "lessThan": "3d39238991e7",
        "status": "affected",
        "versionType": "git"
      },
      {
        "version": "1da177e4c3f4",
        "lessThan": "def054b01a86",
        "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/iommu/intel/dmar.c",
      "drivers/iommu/intel/iommu.c",
      "drivers/iommu/intel/iommu.h",
      "drivers/iommu/intel/svm.c"
    ],
    "versions": [
      {
        "version": "6.8.2",
        "lessThanOrEqual": "6.8.*",
        "status": "unaffected",
        "versionType": "custom"
      },
      {
        "version": "6.9",
        "lessThanOrEqual": "*",
        "status": "unaffected",
        "versionType": "original_commit_for_fix"
      }
    ]
  }
]

6.8 Medium

AI Score

Confidence

Low

0.0004 Low

EPSS

Percentile

9.0%