Skip to content
Noroxi
NVD / CVE Program· CNA redhat

CVE-2018-16840: 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.

CriticalCVSS 9.8 · v3.1—No exploit Fix available

Noroxi assessment

Priority: Plan (action score 40/100)

  • The sources we track (CISA KEV, Exploit-DB, Metasploit, Nuclei, GitHub) show no public exploit code or exploitation in the wild.
  • Probability of exploitation in the next 30 days: 3.4% (FIRST EPSS); higher than 89.1% of all records.
  • Anyone who can reach it over the internet can trigger it. No account or password is required. No user action is required. No special conditions are required; it is repeatable.
  • Fixed version: curl (Alpine:v3.10) 7.62.0-r0; curl (Alpine:v3.5) 7.61.1-r1; curl (Debian:12) 7.62.0-1.
  • Severity is disputed: the assigning authority (CNA) scores it 4.3, NVD 9.8.

Add it to your regular patch cycle. Upgrade to curl (Alpine:v3.10) 7.62.0-r0; curl (Alpine:v3.5) 7.61.1-r1; curl (Debian:12) 7.62.0-1 or later.

Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it

Primary sources: NVD · CVE.org · FIRST EPSS

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.

Published
Oct 31, 2018
Updated
Jun 16, 2026
EPSS
3.4% · 89th percentile

Report tools

JSON

Action score

40

Plan

Add it to your regular patch cycle.

CVSS
39 / 40 · 9.8 / 10
CISA KEV
0 / 30 · Not listed
EPSS
1 / 30 · 3.4%

CISA SSVC decision

Exploitation
none
Automatable
no
Technical impact
partial

Vulnrichment: CISA's decision-tree inputs.

CNA vs NVD score

NVD
9.8
CNA · redhat
4.3
5.5 point gap

CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N

The score given by the assigning authority versus NVD’s independent score. A gap means the severity is contested.

Get told when this record changes

  • Not in KEV: no record of exploitation in the wild
  • No public exploit code on record
  • A fix has been released

If any of these changes, we'll tell you in the daily email digest.

Follow CVE-2018-16840

When you'll hear from us

  • when it enters CISA KEV
  • when exploit code appears or is weaponized
  • when the record is updated (including a fixed version)
  • when EPSS rises 20 points in a week

One daily email digest (06:00 UTC); connect a webhook for KEV listings and weaponized exploits every 10 minutes on paid plans, on the hour on the free plan.

Your free account also gets you

  • CVE alerts: add the products and versions you run, get the new CVEs that affect them
  • Uptime monitoring: 1 site, instant email when it goes down
  • Add your domain: subdomains and takeover risk scanned every week (1 domain)
  • 10 scans an hour on the security tools, at most 30 a day (3 a day without an account), an API key and MCP
  • All your scans in one panel: findings, what changed in the last scan, a report per domain or per client (PDF, share link)
All free tools
Is your version affected? Check it

Noroxi analysis

What does it mean in your environment?

The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.

We use this product, ask for help

Affected systems

Is your version affected?

Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.

VendorProduct
haxxcurl
canonicalubuntu linux

Versions reported by the vendor

Affected version ranges reported by the assigning authority (redhat). Independent of NVD's CPE analysis and usually ahead of it.

  • The Curl Project curl

    • from 7.59.0 to 7.61.1affected

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
Alpine:v3.10curlfrom 7.59.0 · before 7.62.0-r07.62.0-r0
Alpine:v3.5curlfrom 7.59.0 · before 7.61.1-r17.61.1-r1
Debian:12curlbefore 7.62.0-17.62.0-1
SUSE:Linux Enterprise Desktop 12 SP3curlbefore 7.37.0-37.31.17.37.0-37.31.1
SUSE:Linux Enterprise Desktop 12 SP4curlbefore 7.60.0-4.3.17.60.0-4.3.1
SUSE:Linux Enterprise Module for Basesystem 15curlbefore 7.60.0-3.14.37.60.0-3.14.3
SUSE:Linux Enterprise Server 11-SECURITYcurl-openssl1before 7.37.0-70.38.17.37.0-70.38.1
SUSE:Linux Enterprise Software Development Kit 11 SP4curlbefore 7.37.0-70.38.17.37.0-70.38.1

Same product

haxx: all records

Other highest-scoring records for the same primary product.

  • CVE-2021-22901curl 7.75.0 through 7.76.1 suffers from a use-after-free vulnerability resulting in already freed memory being used when a TLS 1.3 session…
    51Plan
  • CVE-2023-38039When curl retrieves an HTTP response, it stores the incoming headers so that they can be accessed later via the libcurl headers API.
    47Plan
  • CVE-2024-2398HTTP/2 push headers memory-leak
    45Plan

Published before and after this one in the same product

  • ← EarlierCVE-2003-1605Aug 23, 2018 · curl 7.x before 7.10.7 sends CONNECT proxy credentials to the remote server.
    31Monitor
  • ← EarlierCVE-2018-16839Oct 31, 2018 · Curl versions 7.33.0 through 7.61.1 are vulnerable to a buffer overrun in the SASL authentication code that may lead to denial of service.
    41Plan
  • Later →CVE-2018-16842Oct 31, 2018 · Curl versions 7.14.1 through 7.61.1 are vulnerable to a heap-based buffer over-read in the tool_msgs.c:voutf() function that may result in…
    37Monitor

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
alpine:curl7.62.0-r0 · Alpine:v3.10Package registry (OSV)
debian:curl7.62.0-1 · Debian:12Package registry (OSV)
suse:curl7.37.0-37.31.1 · SUSE:Linux Enterprise Desktop 12 SP3Package registry (OSV)
suse:curl-openssl17.37.0-70.38.1 · SUSE:Linux Enterprise Server 11-SECURITYPackage registry (OSV)

Exploit status

No known public exploit

No public exploit has been observed yet. That doesn't mean you're safe, only that the bar is a little higher.

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

No dated events beyond publication.

Patch and commit links

Commit, PR and diff links among the references. A starting point for patch-diffing and variant hunting; fixes, not exploits.

Not on record for this CVE: EPSS history · researcher credit · variant or chain candidate · public bounty program.

Technical details

Attack conditions

  • Anyone who can reach it over the internet can trigger it.
  • No account or password is required.
  • No user action is required.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
high · data can be read
Integrity
high · data or configuration can be modified
Availability
high · the service can be disrupted
Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality impact
High
Integrity impact
High
Availability impact
High

Weakness class (CWE)

CWE-416 · Use After Free

CVSS vector

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

nvd-primary

Root cause

After a memory region is freed, another reference pointing to it is still used. By then, the same region may have been allocated for different data.

A representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.

Vulnerable

c
free(dev->buf);/* ... another thread is still running ... */process(dev->buf);

Fixed

c
lock(&dev->lock);free(dev->buf);dev->buf = NULL;unlock(&dev->lock);

Attack context

MITRE CAPEC attack patterns and ATT&CK techniques for this weakness class (CWE). A starting point for detection rules and threat hunting.

MITRE has no CAPEC/ATT&CK mapping for this CWE.

References

All records