CVE-2020-10691 is a medium-severity (CVSS 5.2) Path Traversal vulnerability in ansible. A fix is available for ansible — see the affected versions and patch details below.
Path Traversal in Ansible
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2020-10691 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,987 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
ansibleReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects PyPI packages — download data is not available via public APIs for these ecosystems.
Description
An archive traversal flaw was found in all ansible-engine versions 2.9.x prior to 2.9.7, when running ansible-galaxy collection install. When extracting a collection .tar.gz file, the directory is created without sanitizing the filename. An attacker could take advantage to overwrite any file within the system.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐍PyPI | ansible | ≥ 2.9.0a1&&< 2.9.7 | 2.9.7pip install --upgrade 'ansible==2.9.7' |
Affected Products
ansible engineredhatansible towerredhatDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for ansible, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update ansible to 2.9.7 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2020-10691 is resolved across your whole dependency graph.
Workarounds
Resolve every user-supplied path to its canonical form and reject anything that escapes the intended directory, and run the component under an account that has no read or write access outside the directory it legitimately serves.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
Ansible Engine 2.9.6 as well as previous 2.9.x versions are affected. Ansible versions less than or equal to 2.8 are not affected by this vulnerability as this functionality was introduced on 2.9. Ansible Tower 3.6.3 as well as previous 3.6.x versions are affected as they use ansible-galaxy collections.
A possible mitigation of archive traversal issue could be done by restricting file access control and directory write accesses for extracting tarball files. This is feasible only for scenarios when the destination path could be known and enforced beforehand.Source: Red Hat security advisory for CVE-2020-10691 (CC BY 4.0)
| Product | Fixed in | Advisory |
|---|---|---|
| Red Hat Ansible Engine 2.9 for RHEL 7 | ansible-0:2.9.7-1.el7ae | RHSA-2020:1541 |
| Red Hat Ansible Engine 2 for RHEL 7 | ansible-0:2.9.7-1.el7ae | RHSA-2020:1542 |
| Red Hat Ansible Tower 3.6 for RHEL 7 | ansible-tower-36/ansible-tower:3.6.4-1 | RHBA-2020:1540 |
Frequently Asked Questions
Is CVE-2020-10691 in your dependencies?
Find it across PyPI, including transitive dependencies.