CVE-2021-47541
net/mlx4_en: Fix an use-after-free bug in mlx4_en_try_alloc_resources()
Mitigation
- No fix listed yet: follow the vendor advisory.
Who should check
- Anyone running Linux >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < be12572c5ddc8ad7453bada4eec8fa46967dc757; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 676dc7d9b15bf8733233a2db1ec3f9091ab34275; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < e461a9816a1ac5b4aeb61621b817225b61e46a68; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < f1d43efa59f1edd3e7eca0e94559b4c6b1cd4e2b; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 75917372eef0dbfb290ae45474314d35f97aea18; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < addad7643142f500080417dd7272f49b7a185570
- Anyone running Linux 4.7
Vulnerability facts
- Affected
- Linux >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < be12572c5ddc8ad7453bada4eec8fa46967dc757; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 676dc7d9b15bf8733233a2db1ec3f9091ab34275; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < e461a9816a1ac5b4aeb61621b817225b61e46a68; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < f1d43efa59f1edd3e7eca0e94559b4c6b1cd4e2b; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 75917372eef0dbfb290ae45474314d35f97aea18; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < addad7643142f500080417dd7272f49b7a185570; Linux 4.7
- Fixed in
- Linux 676dc7d9b15bf8733233a2db1ec3f9091ab34275, Linux 75917372eef0dbfb290ae45474314d35f97aea18
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 7.8 (v3.1, CNA)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Privileges required: Low
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: High
- Integrity impact: High
- Availability impact: High
- EPSS
- 0.32% chance of exploitation in 30 days (percentile 18, 2026-11-26)
- CWE
- CWE-416
- Modified
Description
In the Linux kernel, the following vulnerability has been resolved: net/mlx4_en: Fix an use-after-free bug in mlx4_en_try_alloc_resources() In mlx4_en_try_alloc_resources(), mlx4_en_copy_priv() is called and tmp->tx_cq will be freed on the error path of mlx4_en_copy_priv(). After that mlx4_en_alloc_resources() is called and there is a dereference of &tmp->tx_cq[t][i] in mlx4_en_alloc_resources(), which could lead to a use after free problem on failure of mlx4_en_copy_priv(). Fix this bug by adding a check of mlx4_en_copy_priv() This bug was found by a static analyzer. The analysis employs differential checking to identify inconsistent security operations (e.g., checks or kfrees) between two code paths and confirms that the inconsistent operations are not recovered in the current function or the callers, so they constitute bugs. Note that, as a bug found by static analysis, it can be a false positive or hard to trigger. Multiple researchers have cross-reviewed the bug. Builds with CONFIG_MLX4_EN=m show no new warnings, and our static analyzer no longer warns about this code.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Linux | >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < be12572c5ddc8ad7453bada4eec8fa46967dc757; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 676dc7d9b15bf8733233a2db1ec3f9091ab34275; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < e461a9816a1ac5b4aeb61621b817225b61e46a68; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < f1d43efa59f1edd3e7eca0e94559b4c6b1cd4e2b; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 75917372eef0dbfb290ae45474314d35f97aea18; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < addad7643142f500080417dd7272f49b7a185570 | — | cvelist |
| Linux | 4.7 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2021-47541. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2021-47541.md Affected: Linux >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < be12572c5ddc8ad7453bada4eec8fa46967dc757; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 676dc7d9b15bf8733233a2db1ec3f9091ab34275; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < e461a9816a1ac5b4aeb61621b817225b61e46a68; >= ec25bc04ed8e12947738468… Fixed in: Linux 676dc7d9b15bf8733233a2db1ec3f9091ab34275, Linux 75917372eef0dbfb290ae45474314d35f97aea18 Steps: 1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Patches
- https://git.kernel.org/stable/c/be12572c5ddc8ad7453bada4eec8fa46967dc757
- https://git.kernel.org/stable/c/676dc7d9b15bf8733233a2db1ec3f9091ab34275
- https://git.kernel.org/stable/c/e461a9816a1ac5b4aeb61621b817225b61e46a68
- https://git.kernel.org/stable/c/f1d43efa59f1edd3e7eca0e94559b4c6b1cd4e2b
- https://git.kernel.org/stable/c/75917372eef0dbfb290ae45474314d35f97aea18
- https://git.kernel.org/stable/c/addad7643142f500080417dd7272f49b7a185570
FAQ
Is CVE-2021-47541 being exploited?
There is no confirmed exploitation: CVE-2021-47541 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.32% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2021-47541?
High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2021-47541?
Linux >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < be12572c5ddc8ad7453bada4eec8fa46967dc757; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 676dc7d9b15bf8733233a2db1ec3f9091ab34275; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < e461a9816a1ac5b4aeb61621b817225b61e46a68; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < f1d43efa59f1edd3e7eca0e94559b4c6b1cd4e2b; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < 75917372eef0dbfb290ae45474314d35f97aea18; >= ec25bc04ed8e12947738468cbe2191f1529f9e39, < addad7643142f500080417dd7272f49b7a185570; Linux 4.7.
Is there a fix for CVE-2021-47541?
Yes. Fixed in Linux 676dc7d9b15bf8733233a2db1ec3f9091ab34275, Linux 75917372eef0dbfb290ae45474314d35f97aea18. No fix listed yet: follow the vendor advisory.
How do I check if I'm affected by CVE-2021-47541?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.