CVE-2025-21751: net/mlx5: HWS, change error flow on matcher disconnect

Published Feb 27, 2025
·
Updated

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

net/mlx5: HWS, change error flow on matcher disconnect

Currently, when firmware failure occurs during matcher disconnect flow, the error flow of the function reconnects the matcher back and returns an error, which continues running the calling function and eventually frees the matcher that is being disconnected. This leads to a case where we have a freed matcher on the matchers list, which in turn leads to use-after-free and eventual crash.

This patch fixes that by not trying to reconnect the matcher back when some FW command fails during disconnect.

Note that we're dealing here with FW error. We can't overcome this problem. This might lead to bad steering state (e.g. wrong connection between matchers), and will also lead to resource leakage, as it is the case with any other error handling during resource destruction.

However, the goal here is to allow the driver to continue and not crash the machine with use-after-free error.

Affected Software

3 affected componentsFixes available
Linux Kernel
Linux Linux kernel<6.13.3
debian/linux
6.1.176-16.1.190-16.12.107-16.12.113-17.2.12-17.2.13-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 6.1.176-1Fixed in 6.1.190-1Fixed in 6.12.107-1Fixed in 6.12.113-1Fixed in 7.2.12-1Fixed in 7.2.13-1

Event History

Feb 27, 2025
CVE Published
via MITRE·02:12 AM
Data Sourced
via MITRE·02:12 AM
DescriptionSeverity
Data Sourced
via NVD·03:15 AM
RemedyDescriptionSeverityWeaknessAffected Software

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2025-21751?

The severity of CVE-2025-21751 has not been explicitly rated yet, but it involves a vulnerability in the Linux kernel that affects the matcher disconnect procedure.

2

How do I fix CVE-2025-21751?

To fix CVE-2025-21751, users should update their Linux kernel to the latest version where this vulnerability has been addressed.

3

What systems are affected by CVE-2025-21751?

CVE-2025-21751 affects systems running the Linux kernel, particularly those utilizing the mlx5 network driver.

4

What are the potential impacts of CVE-2025-21751?

Exploitation of CVE-2025-21751 could potentially result in unexpected behavior during matcher disconnect, potentially leading to service disruptions.

5

Who should be concerned about CVE-2025-21751?

System administrators and users of affected Linux kernel versions should be concerned about CVE-2025-21751 and take steps to mitigate the risk.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203