CVE-2021-20178: Medium severity redhat ansible vulnerability

Published Jan 11, 2021
·
Updated

A flaw was found in ansible module where credentials are disclosed in the console log by default and not protected by the security feature when using the bitbucketpipelinevariable module. This flaw allows an attacker to steal bitbucketpipeline credentials. The highest threat from this vulnerability is to confidentiality.

Other sources

A flaw was found in ansible. The 'authkey' and 'privkey' credentials are disclosed by default and not protected by nolog feature when using the snmpfacts module. Attackers could take advantage of this information to steal the SNMP credentials. The highest threat from this vulnerability is to data confidentiality.

snmpfacts module in Ansible leaks user authentication such as authKey and privKey. This could lead in disclosing those credentials for every user which has access to the output of playbook execution.

Red Hat

Affected Software

8 affected componentsFixes available
redhat/ansible<0:2.9.18-1.el7ae
0:2.9.18-1.el7ae
redhat/ansible<0:2.9.18-1.el8ae
0:2.9.18-1.el8ae
redhat/ansible<2.9.18
2.9.18
pip/ansible<2.9.18
2.9.18
redhat ansible<2.9.18
redhat Ansible Tower=3.0
Fedoraproject Fedora=32
Fedoraproject Fedora=33

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/ansible to a version that resolves this vulnerability.

    Fixed in 0:2.9.18-1.el7ae
  2. Upgrade

    Upgrade redhat/ansible to a version that resolves this vulnerability.

    Fixed in 0:2.9.18-1.el8ae
  3. Upgrade

    Upgrade pip/ansible to a version that resolves this vulnerability.

    Fixed in 2.9.18
  4. Upgrade

    Upgrade redhat/ansible to a version that resolves this vulnerability.

    Fixed in 2.9.18
  5. Configuration

    Enable no_log for bitbucket_pipeline_variable module invocations to prevent bitbucket_pipeline credentials from being printed to the console output.

    ansible module bitbucket_pipeline_variable no_log = true
  6. Configuration

    Enable no_log for snmp_facts module invocations to prevent authKey and privKey from being disclosed in playbook output.

    ansible module snmp_facts no_log = true
  7. Compensating control

    Restrict access to playbook execution logs and console output to trusted users/systems (limit who can view playbook output) to reduce exposure of credentials until fixes are applied.

Event History

Jan 11, 2021
CVE Published
12:00 AM
Data Sourced
via Red Hat·08:19 AM
DescriptionSeverityAffected Software
May 26, 2021
CVE Published
via MITRE·12:00 AM
Data Sourced
via MITRE·12:00 AM
DescriptionWeakness
Jun 1, 2021
Advisory Published
via GitHub·09:53 PM

Parent advisories

This vulnerability appears in the following advisories.

Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the vulnerability ID of this flaw in Ansible?

The vulnerability ID is CVE-2021-20178.

2

What is the severity level of CVE-2021-20178?

The severity level of CVE-2021-20178 is medium.

3

Which software is affected by this vulnerability?

The affected software includes Ansible, Ansible Tower, and Fedora.

4

How can an attacker exploit the CVE-2021-20178 vulnerability?

An attacker can exploit this vulnerability to steal bitbucket_pipeline credentials.

5

How can I fix the CVE-2021-20178 vulnerability in Ansible?

To fix this vulnerability, update Ansible to version 2.9.18.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203