Skip to main content

Mongoose MQTT Broker EUVDEUVD-2026-140721

| CVE-2026-141511 HIGH
Out-of-bounds Read (CWE-125)
2026-12-01 GitHub_M
8.7
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Reach MQTT broker on TCP 1883
  2. Exploit
    Send malformed SUBSCRIBE packet
  3. Execution
    Out-of-bounds read past datagram boundary
  4. Impact
    Segmentation fault crashes broker (DoS)

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the target to run an MQTT broker built from the Mongoose MQTT broker tutorial (tutorials/mqtt/mqtt-server/main.c) listening on TCP 1883; against such a default-configured tutorial broker, exploitation is remote and unauthenticated (PR:N) with no user interaction, triggered by one crafted SUBSCRIBE packet whose topic position leaves fewer than two bytes for the two-byte topic-length field. The principal limiting factor is deployment scope: the vulnerable parsing code is vendor tutorial/example code rather than the core shipped library, so only installations that adopted that tutorial as a real broker are affected; impact is limited to availability (crash), with no confidentiality or integrity consequence.

Impact

Signals point consistently to a moderate, availability-only risk. The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N) describes a remote, unauthenticated, low-complexity trigger with no attack requirements, and the 8.7 score is driven entirely by high availability impact (VA:H) with zero confidentiality or integrity impact (VC:N/VI:N) - this is a pure denial-of-service, not a code-execution or data-exposure flaw. SSVC reinforces a measured posture: Exploitation=none (no observed in-the-wild activity), Automatable=yes (a single unauthenticated packet, so mass-scannable), Technical Impact=partial. The vuln.today priority is 'this_week', not act_now/emergency. Two caveats must temper the raw score: (1) the defect lives in tutorials/mqtt/mqtt-server/main.c - vendor example/tutorial code - not in the shipped Mongoose library core, so real-world exposure depends on whether an operator deployed that tutorial as a production broker; (2) no EPSS score and no KEV listing are provided, and SSVC Exploitation=none indicates no confirmed active exploitation, so this is a high-CVSS but currently low-real-world-exploitation issue. The input Tag 'Information Disclosure' conflicts with the CVSS (VC:N) and the description (a crash), and should be read as DoS, not disclosure.

Exploit ScenarioDerived

An attacker with network reachability to an MQTT broker built from the Mongoose MQTT broker tutorial sends a single malformed SUBSCRIBE packet to TCP port 1883 whose topic position leaves fewer than two bytes before the datagram boundary. mg_mqtt_next_topic() reads the two-byte topic-length field past msg->dgram.len, causing an out-of-bounds read, a SIGSEGV, and broker crash. The flaw was found via coverage-guided fuzzing (GMPFuzz); no public exploit code is identified in the provided sources at time of analysis.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Dec 02, 2026

Crafted MQTT SUBSCRIBE packets sent to a broker built from the Mongoose MQTT broker tutorial (Cesanta Mongoose before 7.22) drive an out-of-bounds read in mg_mqtt_next_topic() and terminate the process, giving remote, unauthenticated denial of service against the listening broker on TCP 1883. The defect sits in the tutorial's examples code (tutorials/mqtt/mqtt-server/main.c), which reads the two-byte topic-length field without checking that both bytes fall inside msg->dgram.len, so a packet whose topic position leaves fewer than two bytes remaining causes invalid memory access and SIGSEGV. Scope is therefore limited to installations that adopted the tutorial as a production broker; impact is availability only, with no confidentiality or integrity effect, and no public exploit or active exploitation has been identified at time of analysis. Version 7.22 is the vendor-released fix.

RemediationAI

Vendor-released patch: upgrade to Mongoose 7.22 (https://github.com/cesanta/mongoose/releases/tag/7.22), which vendors the fix merged in PR https://github.com/cesanta/mongoose/pull/3611 and commit a9df523f76f43a38bd53b4232b9cfd4c16869e71; the GHSA advisory at https://github.com/cesanta/mongoose/security/advisories/GHSA-94qh-77cf-mpqr confirms the issue as patched. Because the vulnerable logic lives in example code copied into applications, teams that vendored tutorials/mqtt/mqtt-server/main.c must either re-base that file onto the 7.22 version or add a bounds check confirming the topic position plus the two-byte length field stays within msg->dgram.len before calling mg_mqtt_next_topic(). Until the update lands, the practical compensating control is to keep the broker's TCP 1883 listener off untrusted networks (firewall or bind to a management interface), accepting that this breaks connectivity for legitimate remote MQTT clients, and to run the broker under a supervisor that restarts it on crash to limit outage duration, while recognizing that restarts do not prevent the crash itself.

Affected VersionsENISA

Mongoose < 7.22

Affected Packages

euvd mongoose fix: 7.22

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Mongoose is an embedded HTTP/WebSocket/MQTT networking library in C, and the issue class is CWE-125 (out-of-bounds read) arising from missing length validation rather than from an integer overflow or memory corruption primitive. In the MQTT broker tutorial code, mg_mqtt_next_topic() walks topic entries inside a SUBSCRIBE payload using a caller-supplied position; at main.c line 36 it reconstructs the topic length with topic->len = (size_t)(((unsigned) buf[0]) << 8 | buf[1]) where buf is derived from that position, but never verifies that pos + 2 stays within msg->dgram.len. A malformed SUBSCRIBE can therefore set pos to a value beyond the actual payload (the report cites pos=2137), making buf point outside the datagram buffer; the two-byte read then touches memory past the message boundary, which in the observed case faulted with SIGSEGV and crashed the broker. The bug was found by GMPFuzz, a coverage-guided greybox parallel MQTT fuzzer, reported to the vendor on 13 May 2026, and fixed in 7.22. Note that the parsing path lives in vendor tutorial/example code rather than in the core shipped library, which is the main reason the practical exposure is narrower than the network-facing CVSS vector suggests.

Know when Mongoose gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 8.7 HIGH
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
vuln.today AI 7.5 HIGH

Single unauthenticated remote packet to port 1883 triggers the crash (AV:N/AC:L/PR:N/UI:N); impact is crash-only, so C:N/I:N/A:H with no scope change.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Dec 01, 2026 - 22:03 EUVD
CVE Published
Dec 01, 2026 - 20:33 cve.org
HIGH 8.7

DescriptionCVE.org

Mongoose is an embedded web server and network library. Prior to 7.22, the Mongoose MQTT broker tutorial's mg_mqtt_next_topic() function can read two bytes beyond msg->dgram.len when a malformed MQTT SUBSCRIBE packet supplies a topic position that does not leave enough bytes for the topic-length field. Because tutorials/mqtt/mqtt-server/main.c reads that field without validating the complete two-byte access against the datagram boundary, an unauthenticated remote MQTT client can trigger invalid memory access and crash the broker. This issue is fixed in 7.22.

Executive ViewAI

Why It Matters

CVE-2026-141511 is a high-severity denial-of-service flaw in the Mongoose MQTT broker tutorial code that can be triggered by a remote, unauthenticated attacker sending a malformed MQTT packet, causing the broker process to crash. Only organizations that have deployed the Mongoose tutorial as a production MQTT broker on TCP 1883 are affected, and the impact is limited to availability of that broker service, with no data confidentiality or integrity exposure. Leadership should prioritize patching because a service outage could disrupt IoT or messaging operations dependent on the broker.

Business Impact: High
Compensating Controls

Apply vendor patch; if immediate patching is not possible, restrict network access to TCP 1883 to trusted sources and monitor for crash events.

Threat Intelligence Overview

Prevalence
Low
flaw is in Mongoose MQTT broker tutorial/example code, not shipped library core
Data Quality
5 sources
Confidence: Medium
EUVD NVD CVE.org Vulnrichment GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS N/A
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

CVE-2025-23061 CRITICAL POC
9.0 Jan 15

Mongoose ODM for Node.js before version 8.9.5 contains a search injection vulnerability when using $where filters with p

CVE-2017-2894 CRITICAL POC
9.8 Nov 07

An exploitable stack buffer overflow vulnerability exists in the MQTT packet parsing functionality of Cesanta Mongoose 6

CVE-2017-2891 CRITICAL POC
9.8 Nov 07

An exploitable use-after-free vulnerability exists in the HTTP server implementation of Cesanta Mongoose 6.8. Rated crit

CVE-2017-2922 CRITICAL POC
9.8 Nov 07

An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.

CVE-2017-2921 CRITICAL POC
9.8 Nov 07

An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.

CVE-2023-3696 CRITICAL POC
9.8 Jul 17

Prototype Pollution in GitHub repository automattic/mongoose prior to 7.3.4. Rated critical severity (CVSS 9.8), this vu

CVE-2022-2564 CRITICAL POC
9.8 Jul 28

Prototype Pollution in GitHub repository automattic/mongoose prior to 6.4.6. Rated critical severity (CVSS 9.8), this vu

CVE-2019-19307 CRITICAL POC
9.8 Nov 26

An integer overflow in parse_mqtt in mongoose.c in Cesanta Mongoose 6.16 allows an attacker to achieve remote DoS (infin

CVE-2024-53900 CRITICAL POC
9.1 Dec 02

Mongoose before 8.8.3 can improperly use $where in match, leading to search injection. Rated critical severity (CVSS 9.1

CVE-2021-26530 CRITICAL POC
9.1 Feb 08

The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 (compiled with OpenSSL support) is vulnerable to remote OO

CVE-2021-26529 CRITICAL POC
9.1 Feb 08

The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 and 6.7-6.18 (compiled with mbedTLS support) is vulnerable

CVE-2021-26528 CRITICAL POC
9.1 Feb 08

The mg_http_serve_file function in Cesanta Mongoose HTTP server 7.0 is vulnerable to remote OOB write attack via connect

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy