GHSA-28jp-44vh-q42h: Duplicate Advisory Path Traversal Vulnerability
HIGHGHSA-28jp-44vh-q42h is a HIGH path traversal vulnerability (CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')) affecting Duplicate Advisory libraries in the PyPI ecosystem. The issue involves keras keras.utils.get_file api is vulnerable to a path traversal attack. Remediation is available by upgrading affected packages to version 3.12.0.
GHSA-28jp-44vh-q42h at a Glance
How to Fix GHSA-28jp-44vh-q42h
To remediate this vulnerability, upgrade all affected Duplicate Advisory 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 keras>=3.12.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show keras
How to Check if You Are Affected
To determine whether your Python environment is affected by GHSA-28jp-44vh-q42h, inspect your installed packages using pip:
pip show keras
Analyze the terminal output to locate any version of Duplicate Advisory in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.12.0), your application is affected.
Note: The pip show keras command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal'), where the product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory. In Duplicate Advisory, 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
GHSA-28jp-44vh-q42h Affected Duplicate Advisory Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
keras
|
PyPI |
< 3.12.0
|
3.12.0
|
References
Frequently Asked Questions
What is GHSA-28jp-44vh-q42h?
Which Duplicate Advisory versions are affected?
What version fixes GHSA-28jp-44vh-q42h?
Is keras affected?
What CWE is associated with GHSA-28jp-44vh-q42h?
How can I check PyPI dependencies for GHSA-28jp-44vh-q42h?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-28jp-44vh-q42h",
"modified" : "2025-12-02T00:53:21Z",
"published" : "2025-10-30T18:31:10Z",
"withdrawn" : "2025-12-02T00:53:21Z",
"aliases" : [ ],
"summary" : "Duplicate Advisory: Keras keras.utils.get_file API is vulnerable to a path traversal attack",
"details" : "### Duplicate Advisory\nThis advisory has been withdrawn because it is a duplicate of GHSA-hjqc-jx6g-rwp9. This link is maintained to preserve external references.\n\n### Original Description\nThe keras.utils.get_file API in Keras, when used with the extract=True option for tar archives, is vulnerable to a path traversal attack. The utility uses Python's tarfile.extractall function without the filter=\"data\" feature. A remote attacker can craft a malicious tar archive containing special symlinks, which, when extracted, allows them to write arbitrary files to any location on the filesystem outside of the intended destination folder. This vulnerability is linked to the underlying Python tarfile weakness, identified as CVE-2025-4517. Note that upgrading Python to one of the versions that fix CVE-2025-4517 (e.g. Python 3.13.4) is not enough. One additionally needs to upgrade Keras to a version with the fix (Keras 3.12).",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "keras"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "3.12.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/keras-team/keras/security/advisories/GHSA-hjqc-jx6g-rwp9"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-12060"
}, {
"type" : "WEB",
"url" : "https://github.com/keras-team/keras/pull/21760"
}, {
"type" : "WEB",
"url" : "https://github.com/keras-team/keras/commit/47fcb397ee4caffd5a75efd1fa3067559594e951"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/keras-team/keras"
}, {
"type" : "WEB",
"url" : "https://huntr.com/bounties/f94f5beb-54d8-4e6a-8bac-86d9aee103f4"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-22" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2025-10-31T17:39:46Z",
"nvd_published_at" : "2025-10-30T17:15:37Z"
}
}