CVE-2021-21300 (CNNVD-202103-640)
中文标题:
Git 后置链接漏洞
英文标题:
malicious repositories can execute remote code while cloning
漏洞描述
中文描述:
Git是一套免费、开源的分布式版本控制系统。 Git 存在后置链接漏洞,该漏洞允许攻击者利用特别制作的存储库导致just-checked脚本执行而克隆到一个不区分大小写的文件系统。
英文描述:
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.
CWE类型:
标签:
受影响产品
| 厂商 | 产品 | 版本 | 版本范围 | 平台 | CPE |
|---|---|---|---|---|---|
| git | git | >= 2.14.2, < 2.17.62.17.6 | - | - |
cpe:2.3:a:git:git:>=_2.14.2,_<_2.17.62.17.6:*:*:*:*:*:*:*
|
| git | git | >= 2.18.0, < 2.18.5 | - | - |
cpe:2.3:a:git:git:>=_2.18.0,_<_2.18.5:*:*:*:*:*:*:*
|
| git | git | >= 2.19.0, < 2.19.6 | - | - |
cpe:2.3:a:git:git:>=_2.19.0,_<_2.19.6:*:*:*:*:*:*:*
|
| git | git | >= 2.20.0, < 2.20.5 | - | - |
cpe:2.3:a:git:git:>=_2.20.0,_<_2.20.5:*:*:*:*:*:*:*
|
| git | git | >= 2.21.0, < 2.21.4 | - | - |
cpe:2.3:a:git:git:>=_2.21.0,_<_2.21.4:*:*:*:*:*:*:*
|
| git | git | >= 2.22.0, < 2.22.5 | - | - |
cpe:2.3:a:git:git:>=_2.22.0,_<_2.22.5:*:*:*:*:*:*:*
|
| git | git | >= 2.23.0, < 2.23.4 | - | - |
cpe:2.3:a:git:git:>=_2.23.0,_<_2.23.4:*:*:*:*:*:*:*
|
| git | git | >= 2.24.0, < 2.24.4 | - | - |
cpe:2.3:a:git:git:>=_2.24.0,_<_2.24.4:*:*:*:*:*:*:*
|
| git | git | >= 2.25.0, < 2.25.5 | - | - |
cpe:2.3:a:git:git:>=_2.25.0,_<_2.25.5:*:*:*:*:*:*:*
|
| git | git | >= 2.26.0, < 2.26.3 | - | - |
cpe:2.3:a:git:git:>=_2.26.0,_<_2.26.3:*:*:*:*:*:*:*
|
| git | git | >= 2.27.0, < 2.27.1 | - | - |
cpe:2.3:a:git:git:>=_2.27.0,_<_2.27.1:*:*:*:*:*:*:*
|
| git | git | >= 2.28.0, < 2.28.1 | - | - |
cpe:2.3:a:git:git:>=_2.28.0,_<_2.28.1:*:*:*:*:*:*:*
|
| git | git | >= 2.29.0, < 2.29.3 | - | - |
cpe:2.3:a:git:git:>=_2.29.0,_<_2.29.3:*:*:*:*:*:*:*
|
| git | git | >= 2.30.0, < 2.30.1 | - | - |
cpe:2.3:a:git:git:>=_2.30.0,_<_2.30.1:*:*:*:*:*:*:*
|
| git-scm | git | * | - | - |
cpe:2.3:a:git-scm:git:*:*:*:*:*:*:*:*
|
| git-scm | git | 2.27.0 | - | - |
cpe:2.3:a:git-scm:git:2.27.0:*:*:*:*:*:*:*
|
| git-scm | git | 2.28.0 | - | - |
cpe:2.3:a:git-scm:git:2.28.0:*:*:*:*:*:*:*
|
| fedoraproject | fedora | 32 | - | - |
cpe:2.3:o:fedoraproject:fedora:32:*:*:*:*:*:*:*
|
| fedoraproject | fedora | 33 | - | - |
cpe:2.3:o:fedoraproject:fedora:33:*:*:*:*:*:*:*
|
| fedoraproject | fedora | 34 | - | - |
cpe:2.3:o:fedoraproject:fedora:34:*:*:*:*:*:*:*
|
| apple | xcode | * | - | - |
cpe:2.3:a:apple:xcode:*:*:*:*:*:*:*:*
|
| debian | debian_linux | 10.0 | - | - |
cpe:2.3:o:debian:debian_linux:10.0:*:*:*:*:*:*:*
|
解决方案
中文解决方案:
英文解决方案:
临时解决方案:
参考链接
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
cve.org
CVSS评分详情
3.1 (cna)
HIGHCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N
时间信息
利用信息
数据源详情
| 数据源 | 记录ID | 版本 | 提取时间 |
|---|---|---|---|
| CVE | cve_CVE-2021-21300 |
2025-11-11 15:20:47 | 2025-11-11 07:36:37 |
| NVD | nvd_CVE-2021-21300 |
2025-11-11 14:57:34 | 2025-11-11 07:44:58 |
| CNNVD | cnnvd_CNNVD-202103-640 |
2025-11-11 15:10:36 | 2025-11-11 07:56:40 |
版本与语言
安全公告
变更历史
查看详细变更
- vulnerability_type: 未提取 -> 后置链接
- cnnvd_id: 未提取 -> CNNVD-202103-640
- data_sources: ['cve', 'nvd'] -> ['cnnvd', 'cve', 'nvd']
查看详细变更
- affected_products_count: 14 -> 22
- data_sources: ['cve'] -> ['cve', 'nvd']