CVE-2017-7481
published 2018-07-19CVE-2017-7481: Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls…
PriorityP358critical9.8CVSS 3.1
AVNACLPRNUINSUCHIHAH
ITW
Exploited in the wild
EPSS
4.80%
91.0th percentile
Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
Affected
25 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| canonical | ubuntu_linux | — | — |
| canonical | ubuntu_linux | — | — |
| canonical | ubuntu_linux | — | — |
| debian | ansible | < ansible 2.3.1.0+dfsg-1 (bookworm) | ansible 2.3.1.0+dfsg-1 (bookworm) |
| debian | debian_linux | — | — |
| redhat | ansible | >= 0 < 2.3.1.0+dfsg-1 | 2.3.1.0+dfsg-1 |
| redhat | ansible | >= 0 < 2.3.1.0+dfsg-1 | 2.3.1.0+dfsg-1 |
| redhat | ansible | >= 0 < 2.3.1.0+dfsg-1 | 2.3.1.0+dfsg-1 |
| redhat | ansible | >= 0 < 2.3.1.0+dfsg-1 | 2.3.1.0+dfsg-1 |
| redhat | ansible | >= 0 < 2.1.6.0 | 2.1.6.0 |
| redhat | ansible | >= 0 < 2.0.0.2-2ubuntu1.3 | 2.0.0.2-2ubuntu1.3 |
| redhat | ansible | >= 0 < 2.5.1+dfsg-1ubuntu0.1 | 2.5.1+dfsg-1ubuntu0.1 |
| redhat | ansible | >= 2.2.0.0 < 2.2.3.0 | 2.2.3.0 |
| redhat | ansible | >= 2.3.0.0 < 2.3.1.0 | 2.3.1.0 |
| redhat | ansible_engine | < 2.3.1.0 | 2.3.1.0 |
| redhat | ansible_engine | >= 2.3.2.0 < 2.4.0.0 | 2.4.0.0 |
| redhat | gluster_storage | — | — |
| redhat | openshift_container_platform | — | — |
| redhat | openshift_container_platform | — | — |
| redhat | openshift_container_platform | — | — |
| redhat | openstack | — | — |
| redhat | openstack | — | — |
| redhat | storage_console | — | — |
| redhat | virtualization | — | — |
| redhat | virtualization_manager | — | — |
CVSS provenance
nvdv3.19.8CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
nvdv3.05.3MEDIUMCVSS:3.0/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N
nvdv2.07.5HIGHAV:N/AC:L/Au:N/C:P/I:P/A:P
osv9.8CRITICAL
vendor_debian9.8CRITICAL
vendor_redhat9.8CRITICAL
vendor_ubuntu9.8CRITICAL
CVEs like this are exactly what “Exploited This Week” covers.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
Ubuntu
Ansible vulnerabilities
vendor_ubuntu·2019-07-24·CVSS 9.8
CVE-2017-7481 [CRITICAL] Ansible vulnerabilities
Title: Ansible vulnerabilities
Summary: Several security issues were fixed in Ansible.
It was discovered that Ansible failed to properly handle sensitive information.
A local attacker could use those vulnerabilities to extract them.
(CVE-2017-7481)
(CVE-2018-10855)
(CVE-2018-16837)
(CVE-2018-16876)
(CVE-2019-10156)
It was discovered that Ansible could load configuration files from the current
working directory containing crafted commands. An attacker could run arbitrary
code as result.
(CVE-2018-10874)
(CVE-2018-10875)
It was discovered that Ansible fetch module had a path traversal vulnerability.
A local attacker could copy and overwrite files outside of the specified
destination.
(CVE-2019-3828)
Instructions: In general, a standard system update will make all the necessary changes.
Red Hat
ansible: Security issue with lookup return not tainting the jinja2 environment
vendor_redhat·2017-05-09·CVSS 9.8
CVE-2017-7481 [CRITICAL] CWE-20 ansible: Security issue with lookup return not tainting the jinja2 environment
ansible: Security issue with lookup return not tainting the jinja2 environment
Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
An input validation flaw was found in Ansible, where it fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is no
Debian
CVE-2017-7481: ansible - Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin...
vendor_debian·2017·CVSS 9.8
CVE-2017-7481 [CRITICAL] CVE-2017-7481: ansible - Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin...
Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
Scope: local
bookworm: resolved (fixed in 2.3.1.0+dfsg-1)
bullseye: resolved (fixed in 2.3.1.0+dfsg-1)
forky: resolved (fixed in 2.3.1.0+dfsg-1)
sid: resolved (fixed in 2.3.1.0+dfsg-1)
trixie: resolved (fixed in 2.3.1.0+dfsg-1)
OSV
ansible vulnerabilities
osv·2019-07-24·CVSS 9.8
CVE-2017-7481 [CRITICAL] ansible vulnerabilities
ansible vulnerabilities
It was discovered that Ansible failed to properly handle sensitive information.
A local attacker could use those vulnerabilities to extract them.
(CVE-2017-7481)
(CVE-2018-10855)
(CVE-2018-16837)
(CVE-2018-16876)
(CVE-2019-10156)
It was discovered that Ansible could load configuration files from the current
working directory containing crafted commands. An attacker could run arbitrary
code as result.
(CVE-2018-10874)
(CVE-2018-10875)
It was discovered that Ansible fetch module had a path traversal vulnerability.
A local attacker could copy and overwrite files outside of the specified
destination.
(CVE-2019-3828)
OSV
Ansible fails to properly mark lookup-plugin results as unsafe
osv·2018-09-06
CVE-2017-7481 [CRITICAL] Ansible fails to properly mark lookup-plugin results as unsafe
Ansible fails to properly mark lookup-plugin results as unsafe
Ansible before versions 2.1.6.0, 2.2.3.0, 2.3.1.0, and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
GHSA
Ansible fails to properly mark lookup-plugin results as unsafe
ghsa·2018-09-06
CVE-2017-7481 [CRITICAL] CWE-20 Ansible fails to properly mark lookup-plugin results as unsafe
Ansible fails to properly mark lookup-plugin results as unsafe
Ansible before versions 2.1.6.0, 2.2.3.0, 2.3.1.0, and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
OSV
CVE-2017-7481: Ansible before versions 2
osv·2018-07-19·CVSS 9.8
CVE-2017-7481 [CRITICAL] CVE-2017-7481: Ansible before versions 2
Ansible before versions 2.3.1.0 and 2.4.0.0 fails to properly mark lookup-plugin results as unsafe. If an attacker could control the results of lookup() calls, they could inject Unicode strings to be parsed by the jinja2 templating system, resulting in code execution. By default, the jinja2 templating language is now marked as 'unsafe' and is not evaluated.
No detection rules found.
No public exploits indexed.
Bugzilla
Update Ansible to 2.3.1
bugzilla·2017-06-15·CVSS 9.8
CVE-2017-7481 [CRITICAL] Update Ansible to 2.3.1
Update Ansible to 2.3.1
Description of problem:
There is a new release of Ansible in the 2.3 branch: 2.3.1. It fixes several bugs (https://bugzilla.redhat.com/show_bug.cgi?id=1445712, https://bugzilla.redhat.com/show_bug.cgi?id=1456602), among them one security: CVE-2017-7481. It is also already in epel-testing, so when it gets to EPEL, we should make sure the RHEL Extras version is higher, as it will supersede the EPEL version when released.
Version-Release number of selected component (if applicable):
ansible-2.3.0.0-4.el7
Discussion:
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does
Bugzilla
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [epel-all]
bugzilla·2017-05-12·CVSS 9.8
CVE-2017-7481 [CRITICAL] CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [epel-all]
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [epel-all]
This is an automatically created tracking bug! It was created to ensure
that one or more security vulnerabilities are fixed in affected versions
of epel-all.
For comments that are specific to the vulnerability please use bugs filed
against the "Security Response" product referenced in the "Blocks" field.
For more information see:
http://fedoraproject.org/wiki/Security/TrackingBugs
When submitting as an update, use the fedpkg template provided in the next
comment(s). This will include the bug IDs of this tracking bug as well as
the relevant top-level CVE bugs.
Please also mention the CVE IDs being fixed in the RPM changelog and the
fedpkg commit message.
NOTE: this issue affects mul
Bugzilla
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [fedora-all]
bugzilla·2017-05-12·CVSS 9.8
CVE-2017-7481 [CRITICAL] CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [fedora-all]
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment [fedora-all]
This is an automatically created tracking bug! It was created to ensure
that one or more security vulnerabilities are fixed in affected versions
of fedora-all.
For comments that are specific to the vulnerability please use bugs filed
against the "Security Response" product referenced in the "Blocks" field.
For more information see:
http://fedoraproject.org/wiki/Security/TrackingBugs
When submitting as an update, use the fedpkg template provided in the next
comment(s). This will include the bug IDs of this tracking bug as well as
the relevant top-level CVE bugs.
Please also mention the CVE IDs being fixed in the RPM changelog and the
fedpkg commit message.
NOTE: this issue affects
Bugzilla
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment
bugzilla·2017-05-11·CVSS 9.8
CVE-2017-7481 [CRITICAL] CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment
CVE-2017-7481 ansible: Security issue with lookup return not tainting the jinja2 environment
Jason McKerr of Red Hat reports:
Data returned in lookup() variables is not marked as unsafe and could result in unicode strings being passed through to the jinja2 templating system.
Discussion:
Created ansible tracking bugs for this issue:
Affects: epel-all [bug 1450280]
Affects: fedora-all [bug 1450279]
---
upstream fix:
https://github.com/ansible/ansible/commit/ed56f51f185a1ffd7ea57130d260098686fcc7c2
---
This issue has been addressed in the following products:
Red Hat OpenShift Container Platform 3.2
Red Hat OpenShift Container Platform 3.3
Red Hat OpenShift Container Platform 3.4
Red Hat OpenShift Container Platform 3.5
Via RHSA-2017:1244 https://access.redhat.com/errata/RHSA-2017:
http://www.securityfocus.com/bid/98492https://access.redhat.com/errata/RHSA-2017:1244https://access.redhat.com/errata/RHSA-2017:1334https://access.redhat.com/errata/RHSA-2017:1476https://access.redhat.com/errata/RHSA-2017:1499https://access.redhat.com/errata/RHSA-2017:1599https://access.redhat.com/errata/RHSA-2017:2524https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2017-7481https://github.com/ansible/ansible/commit/ed56f51f185a1ffd7ea57130d260098686fcc7c2https://lists.debian.org/debian-lts-announce/2021/01/msg00023.htmlhttps://usn.ubuntu.com/4072-1/http://www.securityfocus.com/bid/98492https://access.redhat.com/errata/RHSA-2017:1244https://access.redhat.com/errata/RHSA-2017:1334https://access.redhat.com/errata/RHSA-2017:1476https://access.redhat.com/errata/RHSA-2017:1499https://access.redhat.com/errata/RHSA-2017:1599https://access.redhat.com/errata/RHSA-2017:2524https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2017-7481https://github.com/ansible/ansible/commit/ed56f51f185a1ffd7ea57130d260098686fcc7c2https://lists.debian.org/debian-lts-announce/2021/01/msg00023.htmlhttps://usn.ubuntu.com/4072-1/
2018-07-19
Published
Exploited in the wild