Vulnerability DatabaseCVE-2026-141511

CVE-2026-141511: 
NixOS vulnerability analysis and mitigation

Overview

CVE-2026-141511 is an out-of-bounds read vulnerability in the Mongoose embedded web server and network library's MQTT broker tutorial code. Specifically, the mg_mqtt_next_topic() function in tutorials/mqtt/mqtt-server/main.c can read two bytes beyond the datagram boundary when processing a malformed MQTT SUBSCRIBE packet. The vulnerability affects Mongoose versions prior to 7.22 (≤ 7.21) and was discovered through fuzzing with GMPFuzz, a coverage-guided greybox parallel MQTT fuzzer; it was reported to the vendor on May 13, 2026, and publicly disclosed on December 1, 2026. It carries a CVSS v4.0 base score of 8.7 (High) (GitHub Advisory, Red Hat Bugzilla).

Technical details

The root cause is an out-of-bounds read (CWE-125) in the mg_mqtt_next_topic() function. At line 36 of tutorials/mqtt/mqtt-server/main.c, the function reads a two-byte topic-length field directly from the payload buffer — topic->len = (size_t)(((unsigned) buf[0]) << 8 | buf[1]) — without first validating that the current position (pos) leaves at least two bytes remaining within msg->dgram.len. An attacker can supply a crafted MQTT SUBSCRIBE packet with a manipulated pos value (e.g., pos=2137) that exceeds the actual payload size, causing buf to point to unmapped or invalid memory and triggering a Segmentation Fault (SIGSEGV). The attack requires no authentication, no privileges, and no user interaction, and is exploitable over the network with low complexity (GitHub Advisory, Red Hat Bugzilla).

Impact

Successful exploitation causes the Mongoose MQTT broker process to crash (Segmentation Fault), resulting in a Denial of Service condition. The impact is limited to availability — there is no evidence of confidentiality or integrity compromise, as the flaw only enables invalid memory reads that crash the process rather than enabling code execution or data exfiltration. Any deployment that builds and runs the Mongoose MQTT broker tutorial code (tutorials/mqtt/mqtt-server/main.c) on versions prior to 7.22 is affected; a single malformed TCP packet to port 1883 is sufficient to bring down the broker (GitHub Advisory, Feedly).

Exploitability

There is no public proof-of-concept exploit and no evidence of in-the-wild exploitation at the time of disclosure (Feedly). The NVD SSVC assessment notes the vulnerability is automatable (no user interaction required) but has only partial technical impact. The EPSS score is approximately 0.0073 (low probability of exploitation in the near term). The vulnerability has not been added to the CISA Known Exploited Vulnerabilities (KEV) catalog. No threat actor attribution has been reported.

Exploitation steps

  1. Reconnaissance: Identify hosts running the Mongoose MQTT broker tutorial (tutorials/mqtt/mqtt-server/main.c) on versions ≤ 7.21, typically listening on TCP port 1883. Tools such as Shodan or Censys can be used to locate exposed MQTT brokers.
  2. Craft malformed SUBSCRIBE packet: Construct an MQTT SUBSCRIBE packet with a manipulated topic position field (e.g., pos=2137) that exceeds the actual payload length, ensuring fewer than two bytes remain for the topic-length field.
  3. Send packet to broker: Transmit the crafted packet over TCP to port 1883 of the target broker without any authentication credentials.
  4. Trigger out-of-bounds read: The mg_mqtt_next_topic() function reads buf[0] and buf[1] from an invalid memory address beyond msg->dgram.len, causing a Segmentation Fault (SIGSEGV) and crashing the broker process, achieving Denial of Service (GitHub Advisory).

Indicators of compromise

  • Network: Unexpected or malformed MQTT SUBSCRIBE packets arriving on TCP port 1883 with anomalously large topic position values; single-packet connections from unknown clients that do not follow normal MQTT handshake patterns.
  • Process: Sudden termination (SIGSEGV / segmentation fault) of the Mongoose MQTT broker process; repeated broker restarts in a short time window.
  • Logs: Operating system crash logs or core dump files referencing the mg_mqtt_next_topic() function or tutorials/mqtt/mqtt-server/main.c; application logs showing abrupt broker shutdown without a clean disconnect message.

Mitigation and workarounds

The vendor has released Mongoose version 7.22, which includes a fix for this vulnerability via commit a9df523f76f43a38bd53b4232b9cfd4c16869e71 (Mongoose 7.22 Release, GitHub PR #3611). Upgrading to version 7.22 or later is the recommended remediation. As an interim workaround, restrict network access to the MQTT broker (TCP port 1883) using firewall rules so that only trusted clients can connect, reducing the attack surface until the patch can be applied (Red Hat Bugzilla).

Community reactions

The vulnerability was noted in the Mongoose 7.22 release notes as part of a substantial batch of security fixes attributed to increased use of AI-powered security tools and contributions from the security research community (Mongoose 7.22 Release). Red Hat tracked the issue via Bugzilla with a high severity rating (Red Hat Bugzilla). No significant broader media coverage or notable researcher commentary beyond the official advisory has been identified.

Additional resources

Linux Distribution fix status

Fix availability across major Linux distributions and their releases.

Ubuntu

Unknown

devel

mongoose

Not Affected

Source: This report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-141471CRITICAL9.1
  • NixOS logoNixOS
  • mongoose
NoYesDec 01, 2026
CVE-2026-141511HIGH8.7
  • NixOS logoNixOS
  • mongoose-lib
NoYesDec 01, 2026
CVE-2026-141472HIGH8.7
  • NixOS logoNixOS
  • mongoose
NoYesDec 01, 2026
CVE-2026-141510MEDIUM5.9
  • NixOS logoNixOS
  • mongoose
NoYesDec 01, 2026
CVE-2026-142248LOW2.3
  • NixOS logoNixOS
  • mlflow
NoNoDec 02, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Additional Wiz resources

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management