Medium

Ansible may expose private key

  • Disclosed: 04.10.2023
  • Updated: 11.10.2026 15:17

A flaw was found in the Ansible Automation Platform. When creating a new keypair, the ec2_key module prints out the private key directly to the standard output. This flaw allows an attacker to fetch those keys from the log files, compromising the system's confidentiality, integrity, and availability.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Python (PyPI) ansible-core >= 2.8.0, <= 2.15.2 no fix

References

CVSS score 6.5/10
CVSS vector
CVSS:3.1/AV:L/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:H
Weakness (CWE)
CWE-497
Platform
Python (PyPI)
Package
ansible-core
Disclosed
04.10.2023
Updated
11.10.2026 15:17

Sources and licenses

OSV / GitHub Advisory Database - PYSEC-2026-1125 - PyPA Advisory Database; CC BY 4.0

OSV / GitHub Advisory Database - GHSA-ww3m-ffrm-qvqv - CC BY 4.0

Vulnerability history: ansible-core

All published vulnerabilities of this package (Python (PyPI)), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
7
First → latest
10.2023 06.2026
Without a fix
1
Exploited in attacks
0

Severity breakdown

  • High 2
  • Medium 4
  • Low 1

Disclosures per year

  1. 2023: 2
  2. 2024: 4
  3. 2025: 0
  4. 2026: 1
  1. High · 7.8 CVE-2026-11332 < 2.16.19rc1, >= 2.17.0b1, < 2.18.18rc1, >= 2.19.0b1, < 2.19.11rc1, >= 2.20.0b1, < 2.20.7rc1, >= 2.21.0b1, < 2.21.1rc1 2.16.19rc1, 2.18.18rc1, 2.19.11rc1, 2.20.7rc1, 2.21.1rc1
  2. Low · 5.5 CVE-2024-11079 >= 2.18.0b1, < 2.18.1rc1, >= 2.17.0b1, < 2.17.7rc1, < 2.16.14rc1 2.18.1rc1, 2.17.7rc1, 2.16.14rc1
  3. Medium · 6.3 CVE-2024-9902 < 2.14.18rc1, >= 2.15.0b1, < 2.15.13rc1, >= 2.16.0b1, < 2.16.13rc1, >= 2.17.0b1, < 2.17.6rc1, >= 2.18.0b1, < 2.18.0rc2 2.14.18rc1, 2.15.13rc1, 2.16.13rc1, 2.17.6rc1, 2.18.0rc2
  4. High · 5.5 CVE-2024-8775 >= 2.17.0b1, < 2.17.6, < 2.16.13 2.17.6, 2.16.13
  5. Medium · 6.6 CVE-2023-5764 >= 2.16.0, < 2.16.1, >= 2.15.0, < 2.15.8, < 2.14.12 2.16.1, 2.15.8, 2.14.12
  6. Ansible may expose private key this entry
    Medium · 6.5 CVE-2023-4237 >= 2.8.0, <= 2.15.2 no fix

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.