PCI: dwc: Fix setting error return on MSI DMA mapping failure
Summary
GSD-2022-1003076: PCI: dwc: Fix setting error return on MSI DMA mapping failure. Affects Kernel versions >= 07940c369a6bf940ec4a00eeb76bf51daa4f3973, < 7c85e29fce090566e08d1bc03fff14d0be140d36. No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The PCI (Peripheral Component Interconnect) subsystem in the Linux Kernel is responsible for managing communication between devices connected to the computer's motherboard. The dwc (DesignWare Cores) driver is used for PCI controllers based on the Synopsys DesignWare Cores. These controllers are commonly found in various devices, including embedded systems and SoCs (System-on-Chips). The dwc driver provides support for features such as MSI (Message Signaled Interrupts) that allow devices to send interrupts directly to the CPU without the need for a separate interrupt line. However, a vulnerability has been identified in the dwc driver that can lead to an error return not being properly set when there is a failure in mapping DMA (Direct Memory Access) for MSI. This vulnerability can potentially be exploited by an attacker to cause a denial-of-service condition or other unexpected behavior in the affected system.
Vulnerability Detail
The vulnerability in the dwc driver arises from a failure to correctly handle errors during the DMA mapping process for MSI. When a device attempts to map DMA for MSI and encounters an error, the dwc driver does not properly set the error return value. This can result in the driver incorrectly reporting success even when the DMA mapping has failed. As a consequence, the affected system may exhibit unexpected behavior or enter an unstable state. An attacker with access to a device utilizing the vulnerable dwc driver could potentially exploit this vulnerability to disrupt the normal operation of the system or trigger a denial-of-service condition.
How To Fix
No fixed version is published for this vulnerability.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
There is no specific workaround mentioned for this vulnerability. Users are advised to apply the recommended fix by updating the Linux Kernel to the latest version.
Conclusion
In conclusion, the dwc driver in the Linux Kernel is vulnerable to a flaw that can result in an error return not being properly set when there is a failure in mapping DMA for MSI. This vulnerability can potentially be exploited to cause a denial-of-service condition or other unexpected behavior in the affected system. To mitigate this vulnerability, it is recommended to update the Linux Kernel to version v5.17.14 or later. Users can use tools like Vulert to check if their system is affected and apply the necessary updates. For further support on vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for Kernel →
FAQ
The vulnerability can potentially be exploited by an attacker to cause a denial-of-service condition or other unexpected behavior in the affected system.
You can use tools like Vulert to check if your system is affected by this vulnerability. Vulert uses a manifest file like package-lock.json to monitor and alert in real-time for open-source vulnerabilities in the software.
At the time of this report, there is no known public exploit for this vulnerability. However, it is always recommended to apply security patches and updates to mitigate potential risks.
The recommended mitigation for this vulnerability is to update the Linux Kernel to version v5.17.14 or later, which includes the fix for this issue.
This vulnerability requires local access to a device utilizing the vulnerable dwc driver. It cannot be exploited remotely over a network.
Related vulnerabilities
Recent vulnerabilities recorded for Kernel.