CVE-2018-16840
highpriority · track · 40EPSS 0.034 · 89 %ileDEEUUSEPSS · scored 2026-10-27
A heap use-after-free flaw was found in curl versions from 7.59.0 through 7.61.1 in the code related to closing an easy handle. When closing and cleaning up an 'easy' handle in the `Curl_close()` function, the library code first frees a struct (without nulling the pointer) and might then subsequently erroneously write to a struct field within that already freed struct.
cvss
Technical severity, 0–10. One row per scoring source.
base score 0–10 · higher = more severe · hover a vector to decode⚠ sources disagree · medium–critical · 4.3–9.8
ssvc
A stakeholder decision — act, attend, or track — from exploitation and impact.
weaknesses
The CWE weakness classes this flaw belongs to.
affected products (19)
Products and version ranges known to be affected.
advisories (2)
Vendor and ecosystem advisories describing this.
- WID-SEC-W-2023-1641cURL: Mehrere SchwachstellenDeutsch2018-10-30csaf · cert_bundDE
Ein entfernter, anonymer Angreifer kann mehrere Schwachstellen in cURL und libcurl ausnutzen, um Informationen offenzulegen, einen Denial of Service Zustand herbeizuführen und um einen nicht näher spezifizierten Angriff durchzuführen.
- CURL-CVE-2018-16840use after free in handle close2018-10-31vendor · osvUS
libcurl contains a heap use after free flaw in code related to closing an easy handle. When closing and cleaning up an "easy" handle in the `Curl_close()` function, the library code first frees a struct (without clearing the pointer) and might then subsequently erroneously write to a struct field within that already freed struct.
also known as (3)
Other names and identifiers for this entity.
sources
Which sources assert this record, and when.
references (28)
External citations — patches, advisories, analysis.
- http://www.ibm.com/support/docview.wss?uid=ibm10880795cnnvd
- http://www.ibm.com/support/docview.wss?uid=ibm10882106cnnvd
- http://www.securitytracker.com/id/1042013cnnvd
- https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-16840cnnvd
- https://curl.haxx.se/docs/CVE-2018-16840.htmlcnnvd
- https://github.com/curl/curl/commit/81d135d67155c5295b1033679c606165d4e28f3fcnnvd
- https://packetstormsecurity.com/files/152034/Gentoo-Linux-Security-Advisory-201903-03.htmlcnnvd
- https://security.gentoo.org/glsa/201903-03cnnvd
Attackers weaponise vulnerabilities like this against internet-exposed services. See what is exposed on your perimeter with a free passive scan.
Free scan