{"answers":{"affected":"It affects 4 products.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2021-21300 exists.","fix":"Upgrade to a fixed version.","what":"CVE-2021-21300 is a high-severity code injection vulnerability in Apple Xcode, published on 9 Mar 2021. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2021-21300 and fix it if it is affected.\n\nWhat it is: CVE-2021-21300 is a high-severity code injection vulnerability in Apple Xcode, published on 9 Mar 2021. An attacker can exploit it over the internet without logging in, 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-2021-21300 exists.\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-2021-21300/ (Markdown: https://insights.sbomify.com/CVE-2021-21300/index.md)","id":"CVE-2021-21300","markdown":"https://insights.sbomify.com/CVE-2021-21300/index.md","name":"CVE-2021-21300","record":{"aliases":["ALPINE-CVE-2021-21300","CLEANSTART-2026-PC25111","DEBIAN-CVE-2021-21300","GHSA-8prw-h3cq-mghm","MGASA-2021-0137","OESA-2021-1105","SUSE-SU-2021:0756-1","SUSE-SU-2021:0757-1","SUSE-SU-2021:2555-1","UBUNTU-CVE-2021-21300","USN-4761-1","openSUSE-SU-2021:0405-1","openSUSE-SU-2021:2555-1","openSUSE-SU-2024:10787-1"],"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":"none","summary":"Attackers can execute arbitrary code by cloning malicious repositories with symbolic links and clean/smudge filters on case-insensitive file systems.","user_interaction":"required","vuln_class":"code_injection"},"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,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N","version":"3.1"},"cwes":[{"id":"CWE-59","name":"Improper Link Resolution Before File Access"}],"description":"Git is an open-source distributed revision control system. In affected versions of Git a specially crafted repository that contains symbolic links as well as files using a clean/smudge filter such as Git LFS, may cause just-checked out script to be executed while cloning onto a case-insensitive file system such as NTFS, HFS+ or APFS (i.e. the default file systems on Windows and macOS). Note that clean/smudge filters have to be configured for that. Git for Windows configures Git LFS by default, and is therefore vulnerable. The problem has been patched in the versions published on Tuesday, March 9th, 2021. As a workaound, if symbolic link support is disabled in Git (e.g. via `git config --global core.symlinks false`), the described attack won't work. Likewise, if no clean/smudge filters such as Git LFS are configured globally (i.e. _before_ cloning), the attack is foiled. As always, it is best to avoid cloning repositories from untrusted sources. The earliest impacted version is 2.14.2. The fix versions are: 2.30.1, 2.29.3, 2.28.1, 2.27.1, 2.26.3, 2.25.5, 2.24.4, 2.23.4, 2.22.5, 2.21.4, 2.20.5, 2.19.6, 2.18.5, 2.17.62.17.6.","ecosystems":["SUSE:Enterprise Storage 6","SUSE:HPE Helion OpenStack 8","SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS","SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS","SUSE:Linux Enterprise High Performance Computing 15-ESPOS","SUSE:Linux Enterprise High Performance Computing 15-LTSS","SUSE:Linux Enterprise Module for Basesystem 15 SP2","SUSE:Linux Enterprise Module for Basesystem 15 SP3","SUSE:Linux Enterprise Module for Development Tools 15 SP2","SUSE:Linux Enterprise Module for Development Tools 15 SP3","SUSE:Linux Enterprise Server 12 SP2-BCL","SUSE:Linux Enterprise Server 12 SP2-LTSS","SUSE:Linux Enterprise Server 12 SP3-BCL","SUSE:Linux Enterprise Server 12 SP3-LTSS","SUSE:Linux Enterprise Server 12 SP4-LTSS","SUSE:Linux Enterprise Server 12 SP5","SUSE:Linux Enterprise Server 15 SP1-BCL","SUSE:Linux Enterprise Server 15 SP1-LTSS","SUSE:Linux Enterprise Server 15-LTSS","SUSE:Linux Enterprise Server for SAP Applications 12 SP2","SUSE:Linux Enterprise Server for SAP Applications 12 SP3","SUSE:Linux Enterprise Server for SAP Applications 12 SP4","SUSE:Linux Enterprise Server for SAP Applications 12 SP5","SUSE:Linux Enterprise Server for SAP Applications 15","SUSE:Linux Enterprise Server for SAP Applications 15 SP1","SUSE:Linux Enterprise Software Development Kit 12 SP5","SUSE:Manager Proxy 4.0","SUSE:Manager Retail Branch Server 4.0","SUSE:Manager Server 4.0","SUSE:OpenStack Cloud 7","SUSE:OpenStack Cloud 8","SUSE:OpenStack Cloud 9","SUSE:OpenStack Cloud Crowbar 8","SUSE:OpenStack Cloud Crowbar 9","openSUSE:Leap 15.2","openSUSE:Leap 15.3","openSUSE:Tumbleweed"],"exploits":{"exploitdb":0,"first_seen":"2021-03-10","github_poc":14,"max_poc_stars":1,"metasploit":1,"nuclei":0,"refs":[{"date":"2021-03-11T02:57:11Z","kind":"github_poc","ref":"https://github.com/Maskhe/CVE-2021-21300","stars":1,"title":null},{"date":"2021-03-10T08:29:49Z","kind":"github_poc","ref":"https://github.com/AlkenePan/CVE-2021-21300","stars":0,"title":null},{"date":"2021-03-10T16:45:46Z","kind":"github_poc","ref":"https://github.com/Faisal78123/CVE-2021-21300","stars":0,"title":null},{"date":"2021-03-10T17:15:49Z","kind":"github_poc","ref":"https://github.com/erranfenech/CVE-2021-21300","stars":0,"title":null},{"date":"2021-03-11T03:59:49Z","kind":"github_poc","ref":"https://github.com/1uanWu/CVE-2021-21300","stars":0,"title":"remote code exec for git"},{"date":"2021-03-11T09:56:03Z","kind":"github_poc","ref":"https://github.com/Kirill89/CVE-2021-21300","stars":0,"title":null},{"date":"2021-03-15T05:28:47Z","kind":"github_poc","ref":"https://github.com/ETOCheney/cve-2021-21300","stars":0,"title":null},{"date":"2021-04-06T01:44:17Z","kind":"github_poc","ref":"https://github.com/fengzhouc/CVE-2021-21300","stars":0,"title":null}],"tier":"weaponised"},"has_fix":true,"headline":"malicious repositories can execute remote code while cloning","id":"CVE-2021-21300","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"apple:xcode","products":["apple:xcode","debian:debian_linux","fedoraproject:fedora"],"type":"code_injection","year":"2021"},"n_packages":37,"n_references":14,"next":{"headline":"Video feed was captured while user has disabled video","id":"CVE-2021-21301"},"packages":[{"ecosystem":"SUSE:Enterprise Storage 6","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Enterprise%20Storage%206","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:HPE Helion OpenStack 8","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=HPE%20Helion%20OpenStack%208","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015%20SP1-ESPOS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015%20SP1-LTSS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15-ESPOS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015-ESPOS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise High Performance Computing 15-LTSS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20High%20Performance%20Computing%2015-LTSS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP2","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP2","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP3","fixed":["2.31.1-10.3.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP3","source":"SUSE-SU-2021:2555-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Development Tools 15 SP2","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Development%20Tools%2015%20SP2","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Development Tools 15 SP3","fixed":["2.31.1-10.3.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Development%20Tools%2015%20SP3","source":"SUSE-SU-2021:2555-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP2-BCL","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP2-BCL","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP2-LTSS","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP2-LTSS","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP3-BCL","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP3-BCL","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP3-LTSS","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP3-LTSS","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP4-LTSS","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP4-LTSS","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 12 SP5","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2012%20SP5","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server 15 SP1-BCL","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2015%20SP1-BCL","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Server 15 SP1-LTSS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2015%20SP1-LTSS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Server 15-LTSS","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%2015-LTSS","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 12 SP2","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP2","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 12 SP3","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP3","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 12 SP4","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP4","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 12 SP5","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2012%20SP5","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2015","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15 SP1","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Server%20for%20SAP%20Applications%2015%20SP1","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Linux Enterprise Software Development Kit 12 SP5","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Linux%20Enterprise%20Software%20Development%20Kit%2012%20SP5","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:Manager Proxy 4.0","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Manager%20Proxy%204.0","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Manager Retail Branch Server 4.0","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Manager%20Retail%20Branch%20Server%204.0","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:Manager Server 4.0","fixed":["2.26.2-3.31.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20Manager%20Server%204.0","source":"SUSE-SU-2021:0757-1"},{"ecosystem":"SUSE:OpenStack Cloud 7","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20OpenStack%20Cloud%207","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:OpenStack Cloud 8","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20OpenStack%20Cloud%208","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:OpenStack Cloud 9","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20OpenStack%20Cloud%209","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:OpenStack Cloud Crowbar 8","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20OpenStack%20Cloud%20Crowbar%208","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"SUSE:OpenStack Cloud Crowbar 9","fixed":["2.26.2-27.43.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/suse/git\u0026distro=SUSE%20OpenStack%20Cloud%20Crowbar%209","source":"SUSE-SU-2021:0756-1"},{"ecosystem":"openSUSE:Leap 15.2","fixed":["2.26.2-lp152.2.6.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/opensuse/git\u0026distro=openSUSE%20Leap%2015.2","source":"openSUSE-SU-2021:0405-1"},{"ecosystem":"openSUSE:Leap 15.3","fixed":["2.31.1-10.3.1"],"introduced":["0"],"last_affected":[],"package":"git","purl":"pkg:rpm/opensuse/git\u0026distro=openSUSE%20Leap%2015.3","source":"openSUSE-SU-2021:2555-1"},{"ecosystem":"openSUSE:Tumbleweed","fixed":["8.20210903-1.2"],"introduced":["0"],"last_affected":[],"package":"git-annex","purl":"pkg:rpm/opensuse/git-annex\u0026distro=openSUSE%20Tumbleweed","source":"openSUSE-SU-2024:10787-1"}],"prev":{"headline":"Multiple Transfer-Encoding headers misinterprets request payload","id":"CVE-2021-21299"},"products":["git"],"published":"2021-03-09","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":"CC BY 4.0","name":"SUSE","prefix":"SUSE"},{"class":"attribution","licence":"CC BY 4.0","name":"SUSE","prefix":"openSUSE"},{"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)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-03","vendors":["git"]},"summary":"Attackers can execute arbitrary code by cloning malicious repositories with symbolic links and clean/smudge filters on case-insensitive file systems.","url":"https://insights.sbomify.com/CVE-2021-21300/"}