CVE-2017-13090

Source
https://nvd.nist.gov/vuln/detail/CVE-2017-13090
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2017-13090.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2017-13090
Downstream
Related
Published
2017-10-27T19:29:00.377Z
Modified
2025-11-25T11:32:45.911182Z
Severity
  • 8.8 (High) CVSS_V3 - CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H CVSS Calculator
Summary
[none]
Details

The retr.c:fdreadbody() 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:fdread(). As fdread() 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.

References

Affected packages

Git / git.savannah.gnu.org/git/wget.git

Affected ranges

Type
GIT
Repo
http://git.savannah.gnu.org/git/wget.git
Events
Introduced
0 Unknown introduced commit / All previous commits are affected

Git / cgit.git.savannah.gnu.org/cgit/wget.git

Affected ranges

Type
GIT
Repo
https://cgit.git.savannah.gnu.org/cgit/wget.git
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
ba6b44f6745b14dce414761a8e4b35d31b176bba