{
  "id": "CVE-2025-21751",
  "url": "https://poc.griffinguard.io/cve/CVE-2025-21751",
  "published_at": "2025-02-27T02:12:22.177Z",
  "title": "net/mlx5: HWS, change error flow on matcher disconnect",
  "vendor": "Linux",
  "product": "Linux",
  "cvss": {
    "score": 7.8,
    "source": "cisa-adp",
    "vector": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
  },
  "kev": {
    "in_kev": false,
    "added_at": null,
    "days_after_publication": null
  },
  "first_poc": null,
  "poc_repo_count": 0,
  "exploit_count": 0,
  "suspicious_repo_count": 0,
  "edge_device": null,
  "description": "In the Linux kernel, the following vulnerability has been resolved:\n\nnet/mlx5: HWS, change error flow on matcher disconnect\n\nCurrently, when firmware failure occurs during matcher disconnect flow,\nthe error flow of the function reconnects the matcher back and returns\nan error, which continues running the calling function and eventually\nfrees the matcher that is being disconnected.\nThis leads to a case where we have a freed matcher on the matchers list,\nwhich in turn leads to use-after-free and eventual crash.\n\nThis patch fixes that by not trying to reconnect the matcher back when\nsome FW command fails during disconnect.\n\nNote that we're dealing here with FW error. We can't overcome this\nproblem. This might lead to bad steering state (e.g. wrong connection\nbetween matchers), and will also lead to resource leakage, as it is\nthe case with any other error handling during resource destruction.\n\nHowever, the goal here is to allow the driver to continue and not crash\nthe machine with use-after-free error.",
  "cwe": "CWE-416",
  "cpes": [
    "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*"
  ],
  "cvss_by_source": {
    "cisa-adp": 7.8,
    "cna": 7.8
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "\u003e= 472dd792348f6601ccaa97d5626ee4faff891901, \u003c 5682aad0276ff9b9b0eff3188eb6a1f504d6b436",
          "\u003e= 472dd792348f6601ccaa97d5626ee4faff891901, \u003c 23a86c76a1a197e8fbbbd0ce3e826eb58c471624",
          "\u003e= 472dd792348f6601ccaa97d5626ee4faff891901, \u003c 1ce840c7a659aa53a31ef49f0271b4fd0dc10296"
        ],
        "fixed_in": [
          "5682aad0276ff9b9b0eff3188eb6a1f504d6b436",
          "23a86c76a1a197e8fbbbd0ce3e826eb58c471624",
          "1ce840c7a659aa53a31ef49f0271b4fd0dc10296"
        ]
      },
      {
        "vendor": "Linux",
        "product": "Linux",
        "ranges": [
          "6.12"
        ],
        "fixed_in": [
          "0",
          "6.12.48",
          "6.13.3",
          "6.14"
        ]
      }
    ],
    "upgrade": [
      "Upgrade Linux to 5682aad0276ff9b9b0eff3188eb6a1f504d6b436 or 23a86c76a1a197e8fbbbd0ce3e826eb58c471624 or 1ce840c7a659aa53a31ef49f0271b4fd0dc10296 or later.",
      "Upgrade Linux to 0 or 6.12.48 or 6.13.3 or 6.14 or later."
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
