CVE-2023-5189: Galaxy importer Path Traversal Vulnerability
MODERATECVE-2023-5189 is a MODERATE (CVSS 6.3) path traversal vulnerability (CWE-23: Relative Path Traversal) affecting Galaxy importer libraries in the PyPI ecosystem. The issue involves ansible galaxy-importer path traversal vulnerability. Remediation is available in the latest vendor maintenance releases.
CVE-2023-5189 at a Glance
Security Impact
CVSS: 6.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:H/A:N).
How to Fix CVE-2023-5189
To remediate this vulnerability, upgrade all affected Galaxy importer dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install galaxy-importer>=Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show galaxy-importer
How to Check if You Are Affected
To determine whether your Python environment is affected by CVE-2023-5189, inspect your installed packages using pip:
pip show galaxy-importer
Analyze the terminal output to locate any version of Galaxy importer in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The pip show galaxy-importer command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-23: Relative Path Traversal, where the product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize sequences such as ".." that can resolve to a location that is outside of that directory. In Galaxy importer, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-5189 Affected Galaxy importer Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
galaxy-importer
|
PyPI |
≤ 0.4.16
|
|
References
Frequently Asked Questions
What is CVE-2023-5189?
Which Galaxy importer versions are affected?
What version fixes CVE-2023-5189?
Is galaxy-importer affected?
What is the CVSS score of CVE-2023-5189?
What CWE is associated with CVE-2023-5189?
How can I check PyPI dependencies for CVE-2023-5189?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-55g2-vm3q-7w52",
"modified" : "2024-12-06T18:06:33Z",
"published" : "2023-11-15T00:31:08Z",
"aliases" : [ "CVE-2023-5189" ],
"summary" : "Ansible galaxy-importer Path Traversal vulnerability",
"details" : "A path traversal vulnerability exists in Ansible when extracting tarballs. An attacker could craft a malicious tarball so that when using the galaxy importer of Ansible Automation Hub, a symlink could be dropped on the disk, resulting in files being overwritten.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:H/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "galaxy-importer"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"last_affected" : "0.4.16"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-5189"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2023:7773"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2024:1536"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/errata/RHSA-2024:2010"
}, {
"type" : "WEB",
"url" : "https://access.redhat.com/security/cve/CVE-2023-5189"
}, {
"type" : "WEB",
"url" : "https://bugzilla.redhat.com/show_bug.cgi?id=2234387"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/ansible/galaxy-importer"
}, {
"type" : "WEB",
"url" : "https://github.com/ansible/galaxy-importer/blob/2c5c7c05fdfb0835878234b36de32902c703616d/galaxy_importer/collection.py#L160-L165"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-22", "CWE-23" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2023-11-16T20:16:05Z",
"nvd_published_at" : "2023-11-14T23:15:12Z"
}
}