In Git for Windows, the Windows port of Git, no localized messages are shipped with the installer. As a consequence, Git is expected not to localize messages at all, and skips the gettext initialization. However, due to a change in MINGW-packages, the `gettext()` function's implicit initialization no longer uses the runtime prefix but uses the hard-coded path `C:\mingw64\share\locale` to look for localized messages. And since any authenticated user has the permission to create folders in `C:\` (and since `C:\mingw64` does not typically exist), it is possible for low-privilege users to place fake messages in that location where `git.exe` will pick them up in version 2.40.1.
This vulnerability is relatively hard to exploit and requires social engineering. For example, a legitimate message at the end of a clone could be maliciously modified to ask the user to direct their web browser to a malicious website, and the user might think that the message comes from Git and is legitimate. It does require local write access by the attacker, though, which makes this attack vector less likely. Version 2.40.1 contains a patch for this issue. Some workarounds are available. Do not work on a Windows machine with shared accounts, or alternatively create a `C:\mingw64` folder and leave it empty. Users who have administrative rights may remove the permission to create folders in `C:\`.
CVSS Details
- CVSS 3.1 Base Score: 3.3
- CVSS 3.1 Vector: (CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:N/I:L/A:N)
Covered by Rapid7
| Product | Vendor Advisory | Solution File | Added | Published |
|---|---|---|---|---|
| Alma_linux | — | Upgrade gitUpgrade perl-Git-SVNUpgrade gitwebUpgrade git-core-docUpgrade gitkUpgrade git-subtreeUpgrade perl-GitUpgrade git-coreUpgrade git-allUpgrade git-svnUpgrade git-guiUpgrade git-instawebUpgrade git-credential-libsecretUpgrade git-emailUpgrade git-daemon | May 24, 2023 | Apr 25, 2023 |
| Alpine Linux | — | Upgrade git | Mar 26, 2024 | Apr 25, 2023 |
| Centos_linux | — | Upgrade git-allUpgrade git-core-docUpgrade gitkUpgrade git-emailUpgrade git-core-debuginfoUpgrade git-debuginfoUpgrade git-credential-libsecret-debuginfoUpgrade gitwebUpgrade gitUpgrade git-subtreeUpgrade git-instawebUpgrade git-svnUpgrade git-daemon-debuginfoUpgrade git-credential-libsecretUpgrade git-coreUpgrade git-guiUpgrade git-daemonUpgrade perl-Git-SVNUpgrade perl-GitUpgrade git-debugsource | May 23, 2023 | Apr 25, 2023 |
| Debian | — | Upgrade git | Jun 27, 2024 | Apr 25, 2023 |
| Gentoo Linux | — | Upgrade dev-vcs/git. | Dec 28, 2023 | Apr 25, 2023 |
| Huawei Euleros 2_0_sp10 | — | Upgrade git-helpUpgrade git | Jul 18, 2023 | Apr 25, 2023 |
| Huawei Euleros 2_0_sp11 | — | Upgrade git-helpUpgrade git | Jan 10, 2024 | Apr 25, 2023 |
| Huawei Euleros 2_0_sp8 | — | Upgrade git-core-docUpgrade gitUpgrade git-core | Jan 10, 2024 | Apr 25, 2023 |
| Huawei Euleros 2_0_sp9 | — | Upgrade git-helpUpgrade git | Jul 10, 2023 | Apr 25, 2023 |
| Microsoft Visual_studio | — | Update Microsoft Visual Studio 2022 to the latest version in the LTSC 17.4 version stream, or upgrade to a newer supported version of Visual Studio 2022.Update Microsoft Visual Studio 2022 to the latest version in the LTSC 17.6 version stream, or upgrade to a newer supported version of Visual Studio 2022.Update Microsoft Visual Studio 2022 to the latest version in the LTSC 17.0 version stream, or upgrade to a newer supported version of Visual Studio 2022.Update Microsoft Visual Studio 2022 to the latest version in the LTSC 17.2 version stream, or upgrade to a newer supported version of Visual Studio 2022.Update Microsoft Visual Studio 2017 to the latest version in the LTSC 15.9 version stream, or upgrade to a newer supported version of Visual Studio 2017.Update Microsoft Visual Studio 2019 to the latest version in the LTSC 16.11 version stream, or upgrade to a newer supported version of Visual Studio 2019. | Jun 25, 2025 | Jun 13, 2023 |
| Oracle_linux | — | Upgrade git-core-docUpgrade gitkUpgrade gitUpgrade git-coreUpgrade perl-Git-SVNUpgrade git-credential-libsecretUpgrade git-svnUpgrade gitwebUpgrade git-subtreeUpgrade git-emailUpgrade git-guiUpgrade perl-GitUpgrade git-instawebUpgrade git-daemonUpgrade git-all | May 23, 2023 | Apr 25, 2023 |
| Redhat_linux | — | Upgrade git-core-docUpgrade gitwebUpgrade perl-GitUpgrade git-instawebUpgrade git-core-debuginfoUpgrade git-debuginfoUpgrade git-daemonUpgrade git-guiUpgrade git-allUpgrade git-debugsourceUpgrade git-svnUpgrade git-emailNo solution existsUpgrade git-coreUpgrade git-credential-libsecret-debuginfoUpgrade gitUpgrade git-daemon-debuginfoUpgrade gitkUpgrade git-subtreeUpgrade perl-Git-SVNUpgrade git-credential-libsecret | May 23, 2023 | Apr 25, 2023 |
| Rocky_linux | — | Upgrade git-credential-libsecret-debuginfoUpgrade git-debuginfoUpgrade git-subtreeUpgrade git-core-debuginfoUpgrade git-coreUpgrade git-daemonUpgrade git-daemon-debuginfoUpgrade git-debugsourceUpgrade gitUpgrade git-credential-libsecret | Mar 5, 2024 | Apr 25, 2023 |
| Suse | — | Upgrade git-daemonUpgrade git-archUpgrade git-coreUpgrade git-cvsUpgrade git-emailUpgrade git-p4Upgrade git-svnUpgrade perl-gitUpgrade git-guiUpgrade git-webUpgrade gitUpgrade git-credential-libsecretUpgrade gitkUpgrade git-docUpgrade git-credential-gnome-keyring | Apr 27, 2023 | Apr 25, 2023 |
| Ubuntu | — | Upgrade git (Ubuntu Pro)Upgrade git | May 4, 2023 | Apr 25, 2023 |
| Vmware Photon_os | — | Use 'tdnf update' to upgrade all packages to the latest version. | Aug 25, 2025 | Apr 25, 2023 |
Prioritise with Active Threat Intelligence
With curated Threat Intelligence, you can see which vulnerabilities truly put you at risk, prioritize what matters most, and act before attackers do.
Explore Intelligence Hub