CVE-2025-46728
Published: 06 May 2025
Summary
CVE-2025-46728 is a high-severity Uncontrolled Resource Consumption (CWE-400) vulnerability in Cpp-Httplib Project Cpp-Httplib. Its CVSS base score is 7.5 (High).
Operationally, ranked in the top 22.5% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog; a public proof-of-concept is referenced.
Deeper analysis
cpp-httplib is a C++ header-only HTTP/HTTPS server and client library that, prior to version 0.20.1, does not enforce configured request-body size limits when requests use Transfer-Encoding: chunked or omit a Content-Length header. The flaw is tracked as CWE-400 and carries a CVSS 3.1 base score of 7.5 reflecting high availability impact over a network vector with low attack complexity.
A remote attacker with no authentication or user interaction required can send a chunked request that omits the terminating zero-length chunk. The server continues allocating memory for each subsequent chunk without bound, resulting in memory exhaustion that crashes or renders the service unresponsive.
The project’s security advisory and the fix released in 0.20.1 state that size limits are now enforced during parsing and any connection exceeding the limit is terminated immediately. When an immediate library upgrade is not possible, the advisory recommends placing a reverse proxy such as Nginx or HAProxy in front of the application and configuring it to enforce maximum body-size limits.
The associated EPSS score has remained flat at 0.0101 with no material increase since disclosure.
EU & UK References
- 🇪🇺 ENISA EUVD: EUVD-2025-13496
Vulnerability details
cpp-httplib is a C++ header-only HTTP/HTTPS server and client library. Prior to version 0.20.1, the library fails to enforce configured size limits on incoming request bodies when `Transfer-Encoding: chunked` is used or when no `Content-Length` header is provided. A remote…
more
attacker can send a chunked request without the terminating zero-length chunk, causing uncontrolled memory allocation on the server. This leads to potential exhaustion of system memory and results in a server crash or unresponsiveness. Version 0.20.1 fixes the issue by enforcing limits during parsing. If the limit is exceeded at any point during reading, the connection is terminated immediately. A short-term workaround through a Reverse Proxy is available. If updating the library immediately is not feasible, deploy a reverse proxy (e.g., Nginx, HAProxy) in front of the `cpp-httplib` application. Configure the proxy to enforce maximum request body size limits, thereby stopping excessively large requests before they reach the vulnerable library code.
- CWE(s)
Related Threats
No named actor attribution yet. ATT&CK technique mapping in progress for this CVE.
Affected Assets
Mitigating Controls
Likely Mitigating Controls AI
Per-CVE control mapping for this CVE has not run yet; the list below is derived from the weakness types (CWEs) cited in the NVD entry.
Limiting concurrent sessions directly prevents uncontrolled resource consumption by capping the number of active sessions per user or account.
Analysis identifies uncontrolled resource consumption indicative of denial-of-service or abuse attempts.
Contingency plan testing includes resource exhaustion scenarios to verify recovery, making it harder for attackers to sustain exploits that cause uncontrolled consumption.
Updated contingency plans include current procedures to detect, contain, and recover from resource exhaustion, limiting an attacker's ability to sustain impact from uncontrolled consumption.
Alternate site allows resumption of operations if resource exhaustion at the primary site is exploited to cause unavailability.
Alternate telecommunications services enable resumption of essential functions when primary services become unavailable due to uncontrolled resource consumption.
The team can analyze and respond to resource exhaustion incidents, reducing the impact of attacks that exploit uncontrolled consumption weaknesses.
Timely maintenance support and spare parts enable rapid recovery from failures induced by uncontrolled resource consumption, shortening the impact window of denial-of-service attacks.