HTTP: GNU Wget skip_short_body Stack Buffer Overflow

This signature detects attempts to exploit a known vulnerability against GNU wget. A successful attack can lead to a buffer overflow and arbitrary remote code execution within the context of the client.

Extended Description

The http.c:skip_short_body() function is called in some circumstances, such as when processing redirects. 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 skip the chunk in pieces of 512 bytes by using the MIN() macro, but ends up passing the negative chunk length to connect.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.

Affected Products

Debian debian_linux

Short Name
HTTP:STC:GNU-WGET-NEG-CHUNK-BO
Severity
Critical
Recommended
False
Recommended Action
Drop
Category
HTTP
Keywords
Buffer CVE-2017-13089 CVE-2017-13090 GNU Overflow Stack Wget bid:101590 bid:101592 skip_short_body
Release Date
02/09/2023
Supported Platforms

srx-branch-12.3

srx-19.3

srx-branch-19.3

vsrx3bsd-19.2

srx-branch-19.4

vsrx-19.4

mx-12.3

mx-19.4

vmx-19.4

mx-19.3

vsrx3bsd-19.4

srx-19.4

vsrx-12.3

vmx-19.3

vsrx-19.2

srx-12.3

Sigpack Version
3761
False Positive
Unknown
Vendors

Debian

Gnu

Found a potential security threat?