Cloudanix VulnDB

CVE-2014-4877

None

CVSS

—

EPSS

39.9%

Published

Oct 29, 2014

CISA due date

—

Cloudanix analysis

Monitor only SSVC: Track

An old flaw in a common file-download tool lets attackers who control an FTP server write files anywhere on a victim's computer when automatic downloading is turned on, potentially taking over the machine.

Weaponized
Exploitation
Remote Unauthenticated
Attacker needs
None
Complexity
Moderate
Impact
Remote Code Execution
Component
Application
Class
Path Traversal
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

Absolute path traversal via crafted FTP LIST responses containing duplicate filenames where one is marked as a symlink, allowing writes to arbitrary filesystem locations when recursive download is enabled.

Why it matters to the business

Attackers can place and execute malicious code on systems that automatically mirror content from untrusted FTP servers, leading to full host compromise and potential supply-chain poisoning of downloaded artifacts.

How an attack unfolds

A malicious FTP server returns a LIST response with two entries for the same filename; one entry declares the file as a symlink pointing outside the download tree. Wget follows the symlink during recursion and writes attacker-controlled content to arbitrary paths, resulting in code execution.

How to fix it

Upgrade GNU Wget to version 1.16 or later. Disable recursive downloads from untrusted sources until patched. Consider replacing wget with curl or aria2 where recursion from FTP is not required.

How to confirm the fix worked

Run 'wget --version' and confirm 1.16 or newer; test recursive FTP fetches against a controlled server that emits symlink entries and verify writes remain confined to the destination directory.

Typical attack path

  1. Attacker sets up malicious FTP server
  2. Victim runs wget with recursive mode against the server
  3. Server returns specially crafted LIST response
  4. Wget follows symlink and writes payload to arbitrary location
  5. Payload is executed via scheduled task, cron, or user invocation

How to detect it

Search process execution logs and command histories for wget invocations with -r or --recursive flags against external FTP hosts; examine downloaded directory trees for unexpected symlinks or files written outside the intended destination.

What your security team should do

  • Immediately inventory all systems using wget < 1.16 and schedule upgrades
  • Block or sandbox automated wget recursion jobs that contact external FTP servers
  • Add wget version checks to configuration management and CI pipelines

The record

Absolute path traversal vulnerability in GNU Wget before 1.16, when recursion is enabled, allows remote FTP servers to write to arbitrary files, and consequently execute arbitrary code, via a LIST response that references the same filename within two entries, one of which indicates that the filename is for a symlink.

Affected packages

Ecosystem Package Introduced Fixed
Debian:11 wget 0 1.16-1
Debian:12 wget 0 1.16-1
Debian:13 wget 0 1.16-1
Debian:6.0 wget 0 1.12-2.1+deb6u1
Debian:7 wget 0 1.13.4-3+deb7u2
Mageia:3 wget 0 1.14-2.2.mga3
Mageia:4 wget 0 1.14-4.2.mga4
Red Hat:enterprise_linux:6::client wget 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::client wget-debuginfo 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::computenode wget 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::computenode wget-debuginfo 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::server wget 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::server wget-debuginfo 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::workstation wget 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:6::workstation wget-debuginfo 0 0:1.12-5.el6_6.1
Red Hat:enterprise_linux:7::client wget 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::client wget-debuginfo 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::computenode wget 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::computenode wget-debuginfo 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::server wget 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::server wget-debuginfo 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::workstation wget 0 0:1.14-10.el7_0.1
Red Hat:enterprise_linux:7::workstation wget-debuginfo 0 0:1.14-10.el7_0.1
Red Hat:rhel_eus:6.5::computenode wget 0 0:1.12-1.12.el6_5
Red Hat:rhel_eus:6.5::computenode wget-debuginfo 0 0:1.12-1.12.el6_5
Red Hat:rhel_eus:6.5::server wget 0 0:1.12-1.12.el6_5
Red Hat:rhel_eus:6.5::server wget-debuginfo 0 0:1.12-1.12.el6_5
Ubuntu:14.04:LTS wget 0 1.15-1ubuntu1.14.04.1
openSUSE:Tumbleweed wget 0 1.18-2.3

Related vulnerabilities