{"answers":{"affected":"11 open source packages ship an affected version, including ansible-core.","exploited":"There is no known exploitation of CVE-2024-9902 in the wild and no public exploit code.","fix":"Upgrade ansible-core to a fixed version for your release line: 2.14.18rc1, 2.15.13rc1, 2.16.13rc1 or 2.17.6rc1.","what":"CVE-2024-9902 is a medium-severity missing authorization vulnerability in Red Hat Ansible Automation Platform Execution Environments, published on 6 Nov 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2024-9902 and fix it if it is affected.\n\nWhat it is: CVE-2024-9902 is a medium-severity missing authorization vulnerability in Red Hat Ansible Automation Platform Execution Environments, published on 6 Nov 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of CVE-2024-9902 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- ansible-core (PyPI): affected all versions; fixed in 2.14.18rc1, 2.15.13rc1, 2.16.13rc1, 2.17.6rc1, 2.18.0rc2\n- ansible-core (PyPI): affected all versions; fixed in 2.14.18rc1\n- ansible-core (PyPI): affected all versions; fixed in 2.14.18rc1\n- ansible-core (PyPI): affected from 2.15.0b1; fixed in 2.15.13rc1\n- ansible-core (PyPI): affected from 2.15.0b1; fixed in 2.15.13rc1\n- ansible-core (PyPI): affected from 2.16.0b1; fixed in 2.16.13rc1\n- ansible-core (PyPI): affected from 2.16.0b1; fixed in 2.16.13rc1\n- ansible-core (PyPI): affected from 2.17.0b1; fixed in 2.17.6rc1\n- ansible-core (PyPI): affected from 2.17.0b1; fixed in 2.17.6rc1\n- ansible-core (PyPI): affected from 2.18.0b1; fixed in 2.18.0rc2\n- ansible-core (PyPI): affected from 2.18.0b1; fixed in 2.18.0rc2\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2024-9902/ (Markdown: https://insights.sbomify.com/CVE-2024-9902/index.md)","id":"CVE-2024-9902","markdown":"https://insights.sbomify.com/CVE-2024-9902/index.md","name":"CVE-2024-9902","record":{"aliases":["AZL-52384","AZL-52417","DEBIAN-CVE-2024-9902","GHSA-32p4-gm2c-wmch","PYSEC-2026-1121","UBUNTU-CVE-2024-9902"],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["data_modify","privilege_escalation"],"network_reachable":"adjacent_or_local","non_default_config":false,"product_category":"Ansible core module","requires_auth":"low_privilege","summary":"An unprivileged user can overwrite arbitrary files and take ownership when a privileged user runs the Ansible user module against their home directory.","user_interaction":"required","vuln_class":"missing_authorization"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"redhat","cpe":[],"cvss":{"score":6.3,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:L","version":"3.1"},"cwes":[{"id":"CWE-863","name":"Incorrect Authorization"}],"description":"A flaw was found in Ansible. The ansible-core `user` module can allow an unprivileged user to silently create or replace the contents of any file on any system path and take ownership of it when a privileged user executes the `user` module against the unprivileged user's home directory. If the unprivileged user has traversal permissions on the directory containing the exploited target file, they retain full control over the contents of the file as its owner.","ecosystems":["PyPI"],"exploits":{"exploitdb":0,"first_seen":"2026-06-23","github_poc":1,"max_poc_stars":1,"metasploit":0,"nuclei":0,"refs":[{"date":"2026-06-23T14:05:58Z","kind":"github_poc","ref":"https://github.com/M8seven/cve-2026-11837-ansible-posix-authorized-key","stars":1,"title":"CVE-2026-11837: local privilege escalation in the ansible.posix authorized_key module via symlink-following chown. Technical writeup; sibling of CVE-2024-9902."}],"tier":"poc_unverified"},"has_fix":true,"headline":"Ansible-core: ansible-core user may read/write unauthorized content","id":"CVE-2024-9902","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"PyPI","product":null,"products":[],"type":"missing_authorization","year":"2024"},"n_packages":11,"n_references":6,"next":{"headline":"07FLYCMS/07FLY-CMS/07FlyCRM fileUpload unrestricted upload","id":"CVE-2024-9903"},"packages":[{"ecosystem":"PyPI","fixed":["2.14.18rc1","2.15.13rc1","2.16.13rc1","2.17.6rc1","2.18.0rc2"],"introduced":["0","2.15.0b1","2.16.0b1","2.17.0b1","2.18.0b1"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"PYSEC-2026-1121"},{"ecosystem":"PyPI","fixed":["2.14.18rc1"],"introduced":["0"],"last_affected":[],"package":"ansible-core","purl":null,"source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.14.18rc1"],"introduced":["0"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.15.13rc1"],"introduced":["2.15.0b1"],"last_affected":[],"package":"ansible-core","purl":null,"source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.15.13rc1"],"introduced":["2.15.0b1"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.16.13rc1"],"introduced":["2.16.0b1"],"last_affected":[],"package":"ansible-core","purl":null,"source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.16.13rc1"],"introduced":["2.16.0b1"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.17.6rc1"],"introduced":["2.17.0b1"],"last_affected":[],"package":"ansible-core","purl":null,"source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.17.6rc1"],"introduced":["2.17.0b1"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.18.0rc2"],"introduced":["2.18.0b1"],"last_affected":[],"package":"ansible-core","purl":null,"source":"GHSA-32p4-gm2c-wmch"},{"ecosystem":"PyPI","fixed":["2.18.0rc2"],"introduced":["2.18.0b1"],"last_affected":[],"package":"ansible-core","purl":"pkg:pypi/ansible-core","source":"GHSA-32p4-gm2c-wmch"}],"prev":{"headline":"Cross-Site Scripting (XSS) in mudler/localai","id":"CVE-2024-9900"},"products":["Ansible Automation Platform Execution Environments","Red Hat Ansible Automation Platform 2.4 for RHEL 8","Red Hat Ansible Automation Platform 2.4 for RHEL 9","Red Hat Ansible Automation Platform 2.5 for RHEL 8","Red Hat Ansible Automation Platform 2.5 for RHEL 9","Red Hat Enterprise Linux 10","Red Hat OpenStack Platform 17.1 for RHEL 9"],"published":"2024-11-06","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CC BY 4.0","name":"PyPA Advisory Database","prefix":"PYSEC"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":"no","exploitation":"none","technical_impact":"total"},"state":"PUBLISHED","updated":"2025-11-06","vendors":["Red Hat"]},"summary":"An unprivileged user can overwrite arbitrary files and take ownership when a privileged user runs the Ansible user module against their home directory.","url":"https://insights.sbomify.com/CVE-2024-9902/"}