{"answers":{"affected":"It affects 4 products.","exploited":"There is no known exploitation of CVE-2022-39260 in the wild and no public exploit code.","fix":"Upgrade to a fixed version.","what":"CVE-2022-39260 is a high-severity vulnerability in Apple Xcode, published on 19 Oct 2022. Any signed-in user can exploit it over the network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2022-39260 and fix it if it is affected.\n\nWhat it is: CVE-2022-39260 is a high-severity vulnerability in Apple Xcode, published on 19 Oct 2022. Any signed-in user can exploit it over the network, with no action from the victim.\nExploitation: There is no known exploitation of CVE-2022-39260 in the wild and no public exploit code.\n\nAffected product: Apple Xcode. 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-2022-39260/ (Markdown: https://insights.sbomify.com/CVE-2022-39260/index.md)","id":"CVE-2022-39260","markdown":"https://insights.sbomify.com/CVE-2022-39260/index.md","name":"CVE-2022-39260","record":{"aliases":["ALPINE-CVE-2022-39260","CLEANSTART-2026-BE06900","DEBIAN-CVE-2022-39260","GHSA-rjr6-wcq6-83p6","UBUNTU-CVE-2022-39260","USN-5686-2"],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":true,"product_category":"Git version control","requires_auth":"low_privilege","summary":"An integer overflow in git shell allows remote code execution if git shell is enabled as a login shell.","user_interaction":"not_required","vuln_class":"integer_overflow"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"xcode","vendor":"apple"},{"product":"debian_linux","vendor":"debian"},{"product":"fedora","vendor":"fedoraproject"},{"product":"git","vendor":"git-scm"}],"cvss":{"score":8.5,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-787","name":"Out-of-bounds Write"},{"id":"CWE-122","name":"Heap-based Buffer Overflow"}],"description":"Git is an open source, scalable, distributed revision control system. `git shell` is a restricted login shell that can be used to implement Git's push/pull functionality via SSH. In versions prior to 2.30.6, 2.31.5, 2.32.4, 2.33.5, 2.34.5, 2.35.5, 2.36.3, and 2.37.4, the function that splits the command arguments into an array improperly uses an `int` to represent the number of entries in the array, allowing a malicious actor to intentionally overflow the return value, leading to arbitrary heap writes. Because the resulting array is then passed to `execv()`, it is possible to leverage this attack to gain remote code execution on a victim machine. Note that a victim must first allow access to `git shell` as a login shell in order to be vulnerable to this attack. This problem is patched in versions 2.30.6, 2.31.5, 2.32.4, 2.33.5, 2.34.5, 2.35.5, 2.36.3, and 2.37.4 and users are advised to upgrade to the latest version. Disabling `git shell` access via remote logins is a viable short-term workaround.","ecosystems":[],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Git vulnerable to Remote Code Execution via Heap overflow in `git shell`","id":"CVE-2022-39260","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"apple:xcode","products":["apple:xcode","debian:debian_linux","fedoraproject:fedora"],"type":"integer_overflow","year":"2022"},"n_packages":0,"n_references":8,"next":{"headline":"Twig may load a template outside a configured directory when using the filesystem loader","id":"CVE-2022-39261"},"packages":[],"prev":{"headline":"Jadx-gui subject to Denial of Service via Swing HTML rendering","id":"CVE-2022-39259"},"products":["git"],"published":"2022-10-19","related":[{"cvss_score":8.1,"headline":"Git Link Following","id":"CVE-2025-48384","kev_date_added":"2025-08-25","published":"2025-07-08"},{"cvss_score":9.8,"headline":"JGit Improper Input Validation vulnerability","id":"CVE-2014-9390","kev_date_added":null,"published":"2020-02-12"},{"cvss_score":9.8,"headline":"Deserialization of untrusted data in FasterXML jackson-databind","id":"CVE-2019-14379","kev_date_added":null,"published":"2019-07-29"},{"cvss_score":9.8,"headline":"An issue was discovered in certain Apple products.","id":"CVE-2018-4164","kev_date_added":null,"published":"2018-04-03"},{"cvss_score":9.8,"headline":"Use after free in n/a","id":"CVE-2016-0746","kev_date_added":null,"published":"2016-02-15"},{"cvss_score":9.3,"headline":"Missing authorization in n/a","id":"CVE-2004-2687","kev_date_added":null,"published":"2007-09-23"},{"cvss_score":8.8,"headline":"This issue was addressed by enforcing library validation on the affected binaries.","id":"CVE-2026-86948","kev_date_added":null,"published":"2026-10-20"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-03","vendors":["git"]},"summary":"An integer overflow in git shell allows remote code execution if git shell is enabled as a login shell.","url":"https://insights.sbomify.com/CVE-2022-39260/"}