NIST deprecates RSA-2048 from 2030. Find every one of them before attackers do.
🐍
🐍 PyPI
Not in CISA KEV
HIGH severity

CVE-2021-20228 — ansible

HIGHFix: ansible/ansible#73487

CVE-2021-20228 is a high-severity (CVSS 7.5) Information Exposure vulnerability in ansible. A fix is available for ansible — see the affected versions and patch details below.

Ansible Exposes Sensitive Information

Also known asGHSA-5rrg-rr89-x9mvPYSEC-2021-1
Published
Updated
Affected
3 pkgs
Patched
3 / 3
Exploits
None indexed
Exploitation data as of Nov 4, 2026 · OSV.dev, NVD, FIRST.org (EPSS)

EPSS Exploitation Probability

via FIRST.org ↗
2.0%probability of exploitation in next 30 days
Lower Risk-0.02%
Lower risk than most CVEs81th percentile — riskier than 81% of all scored CVEsHighest risk
0.00%0.87%1.74%2.61%0.2%2.0%May 26Sep 26Nov 26

Probability of exploitation in the next 30 days, from FIRST.org EPSS.

How urgent is this, really

Where this sits among everything scored

Real-World Exposure

3 pkgs affected
🐍ansible🐍ansible🐍ansible

Real-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

A flaw was found in the Ansible Engine prior to 2.10.6rc1, 2.9.18rc1, and 2.8.19rc1, where sensitive info is not masked by default and is not protected by the no_log feature when using the sub-option feature of the basic.py module. This flaw allows an attacker to obtain sensitive information. The highest threat from this vulnerability is to confidentiality.

Affected Packages

3 total 3 fixed
EcosystemPackageVulnerable rangeFix
🐍PyPIansible≥ 2.10.0a1&&< 2.10.6rc12.10.6rc1pip install --upgrade 'ansible==2.10.6rc1'
🐍PyPIansible≥ 2.9.0a1&&< 2.9.18rc12.9.18rc1pip install --upgrade 'ansible==2.9.18rc1'
🐍PyPIansibleall versions2.8.19rc1pip install --upgrade 'ansible==2.8.19rc1'

Affected Products

4 products · 6 configurations
OS
debian linuxdebian
1 version
10.0
Application
ansible automation platformredhat
1 version
1.2
Application
ansible engineredhat
3 versions
2.02.92.9.18
Application
ansible towerredhat
1 version
3.0

Detection & mitigation playbook

Open-source dependency
  1. Detect

    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.

  2. Fix

    Update ansible to 2.10.6rc1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2021-20228 is resolved across your whole dependency graph.

  3. Workarounds

    Assume what was exposed is already known: rotate any credential, token or key that the affected component could return, restrict the endpoint to callers that genuinely need it, and strip sensitive fields from responses and error output at the boundary rather than relying on the client not to read them.

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.

Red HatModerate
ProductFixed inAdvisory
Red Hat Ansible Automation Platform 1.2 for RHEL 7ansible-automation-platform/platform-resource-operator-bundle:v0.1.1-1RHSA-2021:1079
Red Hat Ansible Engine 2.9 for RHEL 7ansible-0:2.9.18-1.el7aeRHSA-2021:0664
Red Hat Ansible Engine 2 for RHEL 7ansible-0:2.9.18-1.el7aeRHSA-2021:0663
Red Hat Virtualization 4 for Red Hat Enterprise Linux 8ansible-0:2.9.18-1.el8aeRHSA-2021:2180

Frequently Asked Questions

A flaw was found in the Ansible Engine prior to 2.10.6rc1, 2.9.18rc1, and 2.8.19rc1, where sensitive info is not masked by default and is not protected by the `no_log` feature when using the sub-option feature of the basic.py module. This flaw allows an attacker to obtain sensitive information. The highest threat from this vulnerability is to confidentiality.
O3 Security · Impact-Aware SCA

Is CVE-2021-20228 in your dependencies?

Find it across PyPI, including transitive dependencies.

CVE-2021-20228: ansible — Fixed in 2.10.6rc1