Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Heap buffer bounds checking
MITRE ATT&CK
1 technique across 1 tactic: Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Impact | This vulnerability presents moderate-to-high real-world risk requiring prompt remediation. The CVSS base score of 7.3 accurately reflects the threat profile: network-accessible (AV:N), low attack complexity (AC:L), requires no authentication (PR:N) or user interaction (UI:N), with partial impact across all three security properties (C:L/I:L/A:L). The temporal score factor E:P confirms publicly available exploit code exists, significantly lowering the barrier to exploitation. Attack complexity is genuinely low - any attacker capable of initiating TLS 1.3 connections can deliver malicious certificates. However, the partial CIA impacts (Low across all dimensions) and unsegmented scope (S:U) suggest exploitation may not immediately yield complete system compromise, depending on implementation context and exploit sophistication. The vendor's rapid response with patch 7.21 and explicit commit reference (0d882f1b43ff2308b7486a56a9d60cd6dba8a3f1) demonstrates clear remediation path. Real-world prioritization depends on deployment context: internet-facing Mongoose instances handling TLS 1.3 connections warrant immediate patching, while isolated or TLS-disabled deployments face reduced urgency. No CISA KEV listing indicates no confirmed active exploitation campaigns at time of analysis, though public POC availability means exploitation capability exists in attacker communities. |
| Exploit ScenarioDerived | An unauthenticated remote attacker initiates a TLS 1.3 connection to a vulnerable Mongoose-based web server or IoT device. During the handshake, the attacker presents a specially crafted X.509 certificate containing an oversized or malformed public key field designed to trigger the heap overflow in mg_tls_recv_cert(). The overflow corrupts adjacent heap structures, potentially allowing the attacker to manipulate program execution flow, leak sensitive memory contents, cause denial of service through application crash, or achieve limited code execution depending on heap layout and exploitation technique sophistication. Publicly available exploit code exists, enabling script-level attackers to target vulnerable endpoints without deep technical expertise. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Apr 02, 2026
Heap-based buffer overflow in Cesanta Mongoose versions up to 7.20 allows unauthenticated remote attackers to compromise confidentiality, integrity, and availability through malicious TLS 1.3 handshake manipulation. The vulnerability resides in mg_tls_recv_cert() function's improper handling of the pubkey argument during certificate processing. Publicly available exploit code exists (CVSS temporal E:P), and vendor-released patch is available in version 7.21. CVSS base score 7.3 reflects network-accessible, low-complexity attack requiring no privileges or user interaction.
RemediationAI
Upgrade immediately to Cesanta Mongoose version 7.21 or later, which contains the complete fix via commit 0d882f1b43ff2308b7486a56a9d60cd6dba8a3f1 addressing the heap overflow in mg_tls_recv_cert() function. Download the patched release from https://github.com/cesanta/mongoose/releases/tag/7.21 or apply the specific commit patch from https://github.com/cesanta/mongoose/commit/0d882f1b43ff2308b7486a56a9d60cd6dba8a3f1 if building from source. If immediate upgrade is not feasible, consider temporary risk mitigation by disabling TLS 1.3 support if operationally acceptable, restricting network access to Mongoose-based services to trusted clients only, or deploying network-layer filtering to inspect TLS handshakes for anomalous certificate structures. Verify patched version deployment and conduct regression testing to ensure TLS functionality remains intact post-upgrade. The vendor responded professionally with rapid patch turnaround, making upgrade the strongly preferred remediation path over workarounds.
Affected VersionsENISA
Affected Packages
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
Cesanta Mongoose is a lightweight embedded web server and networking library commonly used in IoT devices, embedded systems, and network appliances. The vulnerability (CWE-122: Heap-based Buffer Overflow) occurs in the TLS 1.3 protocol handler within mongoose.c, specifically in the mg_tls_recv_cert() function responsible for processing certificate data during the TLS handshake. When parsing the pubkey argument from incoming certificate messages, insufficient bounds checking allows an attacker to write beyond allocated heap memory. This classic memory corruption flaw can occur when the library processes malformed or oversized public key data structures in X.509 certificates presented during TLS 1.3 session establishment. The affected component (cpe:2.3:a:cesanta:mongoose:*:*:*:*:*:*:*:*) impacts all Mongoose versions through 7.20.
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
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N/E:P
Primary rating from Vendor (VulDB) · only source for this CVE.
CVSS VectorVendor: VulDB
Lifecycle Timeline
3DescriptionCVE.org
A vulnerability has been found in Cesanta Mongoose up to 7.20. This affects the function mg_tls_recv_cert of the file mongoose.c of the component TLS 1.3 Handler. Such manipulation of the argument pubkey leads to heap-based buffer overflow. The attack may be launched remotely. The exploit has been disclosed to the public and may be used. Upgrading to version 7.21 mitigates this issue. The name of the patch is 0d882f1b43ff2308b7486a56a9d60cd6dba8a3f1. It is advisable to upgrade the affected component. The vendor was contacted early, responded in a very professional manner and quickly released a fixed version of the affected product.
Executive ViewAI
Cesanta Mongoose versions up to 7.20 contain a heap-based buffer overflow in TLS 1.3 certificate processing that allows unauthenticated remote attackers to compromise system confidentiality, integrity, and availability without user interaction. Any organization using Mongoose as an embedded web server or IoT communications component faces immediate risk of remote code execution from internet-facing deployments.
Vendor-released patch: Cesanta Mongoose 7.21. If immediate patching is not feasible, implement network-level controls: restrict inbound TLS connections to trusted IP ranges, disable TLS 1.3 support in favor of TLS 1.2 where operationally viable, and deploy Web Application Firewalls with certificate validation rules. However, these are temporary measures only; patching is mandatory.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
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.
A heap overflow occurs when a program writes data beyond the bounds of a buffer allocated in the heap memory region.
Related Vulnerabilities in Cesanta Mongoose TLS and mDNS Handler Flaws
View all 3Mongoose ODM for Node.js before version 8.9.5 contains a search injection vulnerability when using $where filters with p
An exploitable stack buffer overflow vulnerability exists in the MQTT packet parsing functionality of Cesanta Mongoose 6
An exploitable use-after-free vulnerability exists in the HTTP server implementation of Cesanta Mongoose 6.8. Rated crit
An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.
An exploitable memory corruption vulnerability exists in the Websocket protocol implementation of Cesanta Mongoose 6.8.
Prototype Pollution in GitHub repository automattic/mongoose prior to 7.3.4. Rated critical severity (CVSS 9.8), this vu
Prototype Pollution in GitHub repository automattic/mongoose prior to 6.4.6. Rated critical severity (CVSS 9.8), this vu
An integer overflow in parse_mqtt in mongoose.c in Cesanta Mongoose 6.16 allows an attacker to achieve remote DoS (infin
Mongoose before 8.8.3 can improperly use $where in match, leading to search injection. Rated critical severity (CVSS 9.1
The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 (compiled with OpenSSL support) is vulnerable to remote OO
The mg_tls_init function in Cesanta Mongoose HTTPS server 7.0 and 6.7-6.18 (compiled with mbedTLS support) is vulnerable
The mg_http_serve_file function in Cesanta Mongoose HTTP server 7.0 is vulnerable to remote OOB write attack via connect
EUVD-2026-18170
NVD
CVE.org
EPSS
Vulnrichment
GitHub
VulDB
Exploit-DB