C++ HTTP/HTTPS Library Vulnerability in cpp-httplib by yhirose
CVE-2026-46527

8.7HIGH

Key Information:

Vendor

Yhirose

Vendor
CVE Published:
29 May 2026

What is CVE-2026-46527?

Prior to version 0.44.0, cpp-httplib contains a flaw whereby an attacker can exploit the Server::set_trusted_proxies() function by sending an HTTP request with an X-Forwarded-For header that includes invalid IP segments. This leads to a situation where get_client_ip() attempts to access the first element of an empty vector, resulting in undefined behavior. Commonly, this manifests as a crash of the application, thereby causing a denial of service. Users are advised to upgrade to version 0.44.0 or later to mitigate this issue.

Affected Version(s)

cpp-httplib < 0.44.0

References

CVSS V4

Score:
8.7
Severity:
HIGH
Confidentiality:
None
Integrity:
None
Availability:
High
Attack Vector:
Network
Attack Complexity:
Low
Attack Required:
None
Privileges Required:
Undefined
User Interaction:
None

Timeline

  • Vulnerability published

  • Vulnerability Reserved

.