CVE-2024-42651 Details
Description
NanoMQ v0.17.9 was discovered to contain a heap use-after-free vulnerability via the component sub_Ctx_handle. This vulnerability allows attackers to cause a Denial of Service (DoS) via a crafted SUBSCRIBE message.
A heap use-after-free vulnerability has been identified in NanoMQ version 0.17.9. This issue arises in the component sub_Ctx_handle, where improper memory management of retained messages during multi-topic subscriptions creates a use-after-free scenario. When a client subscribes to multiple topics, NanoMQ matches each topic with retained messages. If a match is found, the message is queued for delivery and then freed, but the pointer is not cleared. If a later topic in the same subscription matches the same freed message, the broker may attempt to reuse the dangling pointer, leading to potential memory corruption, crashes, or arbitrary code execution, depending on the heap layout and exploitation methods used.
Users can update to the latest version of NanoMQ, where this vulnerability has been fixed.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Jul 29, 2025References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/nanomq/nanomq | [email protected] | Product |
| https://github.com/nanomq/nanomq/issues/1217 | [email protected] | ExploitIssue Tracking |
| https://github.com/songxpu/bug_report/blob/master/MQTT/NanoMQ/CVE-2024-42651.md | [email protected] | ExploitThird Party Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-400 | Uncontrolled Resource Consumption | CISA-ADP |
Affected Products
| Product | Versions |
|---|---|
| emqx nanomq | 0.17.9 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Aug 6, 2025 | Initial Analysis | [email protected] |
| Jul 29, 2025 | New CVE Received | [email protected] |
| Jul 29, 2025 | CVE Modified | CISA-ADP |