Synology-SA-17:62 Wget

Publish Time: 2017-11-02 17:37:11 UTC+8

Last Updated: 2018-01-12 11:19:24 UTC+8

Severity
Important
Status
Resolved

Abstract

Multiple security vulnerabilities have been found in Wget, and may allow man-in-the-middle attackers to execute arbitrary codes, or cause denial-of-service attack from a vulnerable version of Synology DiskStation Manager (DSM), Synology Router Manager (SRM), and Download Station.

Severity

Affected

  • Products
    • DSM 6.1
    • DSM 6.0
    • DSM 5.2
    • SRM 1.1
    • Download Station before 3.8.7-3490
  • Models
    • All Synology models

Description

  • CVE-2017-13089 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.
  • CVE-2017-13090 The 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.

Mitigation

None

Update Availability

To fix the security issues: please go to DSM > Package Center and update Download Station to 3.8.7-3490 or above.

For DSM 5.2, DSM 6.0 and DSM 6.1 users, please update DSM to 6.1.4-15217 or above.

Reference