GNU Wget: heap overflow in HTTP protocol handling

Summary

CVECVE-2017-13090
StatePUBLISHED
Assignercertcc
Source PriorityCVE Program / NVD first with legacy fallback
Published2017-10-27 19:29:00 UTC
Updated2025-04-20 01:37:25 UTC
DescriptionThe retr.c:fd_read_body() function is called when processing OK responses. When the response is sent chunked in wget before 1.19.2, the chunk parser uses strtol() to read each chunk's length, but doesn't check that the chunk length is a non-negative number. The code then tries to read the chunk in pieces of 8192 bytes by using the MIN() macro, but ends up passing the negative chunk length to retr.c:fd_read(). As fd_read() takes an int argument, the high 32 bits of the chunk length are discarded, leaving fd_read() with a completely attacker controlled length argument. The attacker can corrupt malloc metadata after the allocated buffer.

Risk And Classification

Primary CVSS: v3.0 8.8 HIGH from [email protected]

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

Problem Types: CWE-122 | CWE-119 | CWE-122 CWE-122: Heap-based Buffer Overflow


VersionSourceTypeScoreSeverityVector
3.0[email protected]Primary8.8HIGHCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
3.0[email protected]Secondary8.8HIGHCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
3.0CNADECLARED8.8HIGHCVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
2.0[email protected]Primary9.3AV:N/AC:M/Au:N/C:C/I:C/A:C

CVSS v3.0 Breakdown

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

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

CVSS v2.0 Breakdown

Access Vector
Network
Access Complexity
Medium
Authentication
None
Confidentiality
Complete
Integrity
Complete
Availability
Complete

AV:N/AC:M/Au:N/C:C/I:C/A:C

NVD Known Affected Configurations (CPE 2.3)

TypeVendorProductVersionUpdateEditionLanguage
Operating System Debian Debian Linux 8.0 All All All
Operating System Debian Debian Linux 9.0 All All All
Application Gnu Wget All All All All

Vendor Declared Affected Products

SourceVendorProductVersionPlatforms
CNA GNU Project Wget affected prior to 1.19.2 any

References

ReferenceSourceLinkTags
Debian -- Security Information -- DSA-4008-1 wget af854a3a-2127-422b-91ae-364da2661108 www.debian.org Issue Tracking, Third Party Advisory
GNU Wget: Multiple vulnerabilities (GLSA 201711-06) — Gentoo Security af854a3a-2127-422b-91ae-364da2661108 security.gentoo.org Issue Tracking, Third Party Advisory
GNU wget CVE-2017-13090 Heap Buffer Overflow Vulnerability af854a3a-2127-422b-91ae-364da2661108 www.securityfocus.com Issue Tracking, Third Party Advisory, VDB Entry
wget.git - GNU Wget af854a3a-2127-422b-91ae-364da2661108 git.savannah.gnu.org Issue Tracking, Patch, Third Party Advisory
wget Buffer Overflows in Processing HTTP Data Lets Remote Users Execute Arbitrary Code - SecurityTracker af854a3a-2127-422b-91ae-364da2661108 www.securitytracker.com Issue Tracking, Third Party Advisory, VDB Entry
Red Hat Customer Portal af854a3a-2127-422b-91ae-364da2661108 access.redhat.com
Synology-SA-17:62 Wget | Synology Inc. af854a3a-2127-422b-91ae-364da2661108 www.synology.com
Viestintävirasto - Critical vulnerabilities in Wget af854a3a-2127-422b-91ae-364da2661108 www.viestintavirasto.fi Issue Tracking, Patch, Third Party Advisory
CVE Program record CVE.ORG www.cve.org canonical
NVD vulnerability detail NVD nvd.nist.gov canonical, analysis

Vendor Comments And Credit

Discovery Credit

CNA: Antti Levomäki, Christian Jalio, Joonas Pihlaja from Forcepoint (en)

Legacy QID Mappings

  • 378216 Virtuozzo Linux Security Update for wget (VZLSA-2017:3075)
  • 500735 Alpine Linux Security Update for wget
  • 504511 Alpine Linux Security Update for wget
  • 710494 Gentoo Linux GNU Wget Multiple Vulnerabilities (GLSA 201711-06)
© CVE.report 2026 |

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report