CVE-2020-1737 Path Traversal in Ansible
An attacker can exploit path traversal in Ansible's win_unzip module to write files outside the destination directory, potentially leading to code execution.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2020-1737?
CVE-2020-1737 is a high-severity path traversal vulnerability in Redhat Ansible Tower, published on 9 Mar 2020. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Official description
A flaw was found in Ansible 2.7.17 and prior, 2.8.9 and prior, and 2.9.6 and prior when using the Extract-Zip function from the win_unzip module as the extracted file(s) are not checked if they belong to the destination folder. An attacker could take advantage of this flaw by crafting an archive anywhere in the file system, using a path traversal. This issue is fixed in 2.10.
Weakness: CWE-22
Which versions are affected by CVE-2020-1737?
7 open source packages ship an affected version, including ansible. It affects 2 products.
| Package | Affected | Fixed in |
|---|---|---|
ansible PyPI | All versions | 2.7.17, 2.8.9, 2.9.6 |
ansible PyPI | All versions | 2.7.17 |
ansible PyPI | All versions | 2.7.17 |
ansible PyPI | From 2.8.0a1 | 2.8.9 |
ansible PyPI | From 2.8.0a1 | 2.8.9 |
ansible PyPI | From 2.9.0a1 | 2.9.6 |
1 more packages
ansible PyPI | From 2.9.0a1 | 2.9.6 |
Products include Redhat Ansible Engine, Redhat Ansible Tower.
How do I fix CVE-2020-1737?
Upgrade ansible to a fixed version for your release line: 2.7.17, 2.8.9 or 2.9.6.
Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.
Is CVE-2020-1737 being exploited?
There is no known exploitation of CVE-2020-1737 in the wild and no public exploit code.
Other vulnerabilities in Redhat Ansible Tower
- CVE-2018-10874 Ansible Improper Input Validation vulnerability
- CVE-2020-1734 OS Command Injection in ansible
- CVE-2019-14858 Ansible leaks sensitive information to logs when told not to
- CVE-2020-10691 Path Traversal in Ansible
- CVE-2018-16859 Ansible Logs Passwords If PowerShell ScriptBlock is Enabled
Sources
Also known as ALPINE-CVE-2020-1737, DEBIAN-CVE-2020-1737, GHSA-893h-35v4-mxqx, PYSEC-2020-9, UBUNTU-CVE-2020-1737.