CVE-2017-1000254
CVE-2017-1000254 is a high-severity vulnerability in Haxx Libcurl with a CVSS 3.x base score of 7.5. It is not currently listed as actively exploited by CISA, and its EPSS exploit-prediction score is low. The underlying weakness is classified as CWE-119.
Key facts
- Severity: High (CVSS 3.x base score 7.5)
- CVSS v2: 5.0
- EPSS exploit prediction: 8% (94th percentile)
- Actively exploited: Not listed in CISA KEV
- Weakness: CWE-119
- Affected product: Haxx Libcurl
- Published:
- Last modified:
Description
libcurl may read outside of a heap allocated buffer when doing FTP. When libcurl connects to an FTP server and successfully logs in (anonymous or not), it asks the server for the current directory with the `PWD` command. The server then responds with a 257 response containing the path, inside double quotes. The returned path name is then kept by libcurl for subsequent uses. Due to a flaw in the string parser for this directory name, a directory name passed like this but without a closing double quote would lead to libcurl not adding a trailing NUL byte to the buffer holding the name. When libcurl would then later access the string, it could read beyond the allocated heap buffer and crash or wrongly access data beyond the buffer, thinking it was part of the path. A malicious server could abuse this fact and effectively prevent libcurl-based clients to work with it - the PWD command is always issued on new FTP connections and the mistake has a high chance of causing a segfault. The simple fact that this has issue remained undiscovered for this long could suggest that malformed PWD responses are rare in benign servers. We are not aware of any exploit of this flaw. This bug was introduced in commit [415d2e7cb7](https://github.com/curl/curl/commit/415d2e7cb7), March 2005. In libcurl version 7.56.0, the parser always zero terminates the string but also rejects it if not terminated properly with a final double quote.
Frequently asked questions
- What is CVE-2017-1000254?
- libcurl may read outside of a heap allocated buffer when doing FTP. When libcurl connects to an FTP server and successfully logs in (anonymous or not), it asks the server for the current directory with the `PWD` command. The server then responds with a 257 response containing the path, inside double quotes. The returned path name is then kept by libcurl for subsequent uses. Due to a flaw in the string parser for this directory name, a directory name passed like this but without a closing double quote would lead to libcurl not adding a trailing NUL byte to the buffer holding the name. When libcurl would then later access the string, it could read beyond the allocated heap buffer and crash or wrongly access data beyond the buffer, thinking it was part of the path. A malicious server could abuse this fact and effectively prevent libcurl-based clients to work with it - the PWD command is always issued on new FTP connections and the mistake has a high chance of causing a segfault. The simple fact that this has issue remained undiscovered for this long could suggest that malformed PWD responses are rare in benign servers. We are not aware of any exploit of this flaw. This bug was introduced in commit [415d2e7cb7](https://github.com/curl/curl/commit/415d2e7cb7), March 2005. In libcurl version 7.56.0, the parser always zero terminates the string but also rejects it if not terminated properly with a final double quote.
- How severe is CVE-2017-1000254?
- CVE-2017-1000254 has a CVSS 3.x base score of 7.5, rated high severity. It is exploitable over network with low attack complexity, requires no privileges and no user interaction. Impact on confidentiality is none, integrity none, and availability high.
- Is CVE-2017-1000254 being actively exploited?
- It is not currently listed in CISA's KEV catalog. Its EPSS exploit-prediction score is 8% (94th percentile), an estimate of the probability of exploitation in the next 30 days.
- What products are affected by CVE-2017-1000254?
- CVE-2017-1000254 primarily affects Haxx Libcurl. In total, 117 product configurations (CPEs) are listed as vulnerable; see the affected-products list for the exact versions.
- How do I fix CVE-2017-1000254?
- Review the linked vendor and NVD advisories for patched versions and mitigations, then upgrade or apply the recommended workaround. Given its high severity, prioritise patching exposed systems.
- When was CVE-2017-1000254 published?
- CVE-2017-1000254 was published on 2017-10-06 and last updated on 2026-06-17.
References
- http://www.debian.org/security/2017/dsa-3992
- http://www.securityfocus.com/bid/101115
- http://www.securitytracker.com/id/1039509
- https://access.redhat.com/errata/RHSA-2018:2486
- https://access.redhat.com/errata/RHSA-2018:3558
- https://curl.haxx.se/673d0cd8.patch
- https://curl.haxx.se/docs/adv_20171004.html
- https://lists.apache.org/thread.html/r58af02e294bd07f487e2c64ffc0a29b837db5600e33b6e698b9d696b%40%3Cissues.bookkeeper.apache.org%3E
- https://lists.apache.org/thread.html/rf4c02775860db415b4955778a131c2795223f61cb8c6a450893651e4%40%3Cissues.bookkeeper.apache.org%3E
- https://security.gentoo.org/glsa/201712-04
- https://support.apple.com/HT208331
Affected products (117)
- cpe:2.3:a:haxx:libcurl:7.7:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.7.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.7.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.7.3:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.8:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.8.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.3:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.4:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.5:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.6:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.7:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.9.8:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.3:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.4:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.5:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.6:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.7:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.10.8:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.11.0:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.11.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.11.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.12.0:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.12.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.12.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.12.3:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.13.0:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.13.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.13.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.14.0:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.14.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.15.0:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.15.1:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.15.2:*:*:*:*:*:*:*
- cpe:2.3:a:haxx:libcurl:7.15.3:*:*:*:*:*:*:*
More vulnerabilities in Haxx Libcurl
- CVE-2023-38545 — Critical (CVSS 9.8): This flaw makes curl overflow a heap based buffer in the SOCKS5 proxy handshake. When curl is asked to pass along the…
- CVE-2019-3822 — Critical (CVSS 9.8): libcurl versions from 7.36.0 to before 7.64.0 are vulnerable to a stack-based buffer overflow. The function creating an…
- CVE-2017-8818 — Critical (CVSS 9.8): curl and libcurl before 7.57.0 on 32-bit platforms allow attackers to cause a denial of service (out-of-bounds access…
- CVE-2017-8817 — Critical (CVSS 9.8): The FTP wildcard function in curl and libcurl before 7.57.0 allows remote attackers to cause a denial of service…
- CVE-2017-8816 — Critical (CVSS 9.8): The NTLM authentication feature in curl and libcurl before 7.57.0 on 32-bit platforms allows attackers to cause a…
- CVE-2016-7167 — Critical (CVSS 9.8): Multiple integer overflows in the (1) curl_escape, (2) curl_easy_escape, (3) curl_unescape, and (4) curl_easy_unescape…
All CVEs affecting Haxx Libcurl →
Other CWE-119 (Improper Restriction of Operations within the Bounds of a Memory Buffer) vulnerabilities
- CVE-2026-2778 — Critical (CVSS 10.0): Sandbox escape due to incorrect boundary conditions in the DOM: Core & HTML component. This vulnerability was fixed in…
- CVE-2026-2776 — Critical (CVSS 10.0): Sandbox escape due to incorrect boundary conditions in the Telemetry component in External Software. This vulnerability…
- CVE-2025-1866 — Critical (CVSS 10.0): Improper Restriction of Operations within the Bounds of a Memory Buffer vulnerability in warmcat libwebsockets allows…
- CVE-2022-27625 — Critical (CVSS 10.0): A vulnerability regarding improper restriction of operations within the bounds of a memory buffer is found in the…
- CVE-2022-27624 — Critical (CVSS 10.0): A vulnerability regarding improper restriction of operations within the bounds of a memory buffer is found in the…
- CVE-2020-11896 — Critical (CVSS 10.0): The Treck TCP/IP stack before 6.0.1.66 allows Remote Code Execution, related to IPv4 tunneling.