{"answers":{"affected":"","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-12638 exists.","fix":"Apply the vendor's patch.","what":"CVE-2025-12638 is a high-severity path traversal vulnerability in keras-team/keras, published on 28 Nov 2025. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2025-12638 and fix it if it is affected.\n\nWhat it is: CVE-2025-12638 is a high-severity path traversal vulnerability in keras-team/keras, published on 28 Nov 2025. Any signed-in user can exploit it over the network, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-12638 exists.\n\nAffected product: keras-team/keras. No package-level version data is available, so check the vendor advisory linked from the reference page.\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-2025-12638/ (Markdown: https://insights.sbomify.com/CVE-2025-12638/index.md)","id":"CVE-2025-12638","markdown":"https://insights.sbomify.com/CVE-2025-12638/index.md","name":"CVE-2025-12638","record":{"aliases":["AZL-71185","DEBIAN-CVE-2025-12638","UBUNTU-CVE-2025-12638"],"analysis":{"component_type":"library","fix_type":"patch","impacts":["code_execution","data_modify"],"network_reachable":"yes","non_default_config":false,"product_category":"Keras deep learning library","requires_auth":"low_privilege","summary":"Attackers can write arbitrary files outside the cache directory via path traversal in Keras get_file(), potentially leading to code execution.","user_interaction":"required","vuln_class":"path_traversal"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"@huntr_ai","cpe":[],"cvss":{"score":8,"severity":"high","source":"cna","vector":"CVSS:3.0/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","version":"3.0"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"description":"Keras version 3.11.3 is affected by a path traversal vulnerability in the keras.utils.get_file() function when extracting tar archives. The vulnerability arises because the function uses Python's tarfile.extractall() method without the security-critical filter='data' parameter. Although Keras attempts to filter unsafe paths using filter_safe_paths(), this filtering occurs before extraction, and a PATH_MAX symlink resolution bug triggers during extraction. This bug causes symlink resolution to fail due to path length limits, resulting in a security bypass that allows files to be written outside the intended extraction directory. This can lead to arbitrary file writes outside the cache directory, enabling potential system compromise or malicious code execution. The vulnerability affects Keras installations that process tar archives with get_file() and does not affect versions where this extraction method is secured with the appropriate filter parameter.","ecosystems":[],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"Path Traversal Vulnerability in keras-team/keras via Tar Archive Extraction in keras.utils.get_file()","id":"CVE-2025-12638","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":null,"products":[],"type":"path_traversal","year":"2025"},"n_packages":0,"n_references":1,"next":{"headline":"Missing authorization in wModes – Catalog Mode, Product Pricing, Enquiry Forms \u0026 Promotions | for WooCommerce","id":"CVE-2025-12639"},"packages":[],"prev":{"headline":"Elastic Theme Editor \u003c= 0.0.3 - Authenticated (Subscriber+) Arbitrary File Upload","id":"CVE-2025-12637"},"products":["keras-team/keras"],"published":"2025-11-28","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"total"},"state":"PUBLISHED","updated":"2025-11-28","vendors":["keras-team"]},"summary":"Attackers can write arbitrary files outside the cache directory via path traversal in Keras get_file(), potentially leading to code execution.","url":"https://insights.sbomify.com/CVE-2025-12638/"}