# CVE-2023-29012: Git CMD erroneously executes \`doskey.exe\` in the current directory, if it exists

- Priority: **Routine**
- Reason: Not severe (CVSS 7.3, local access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2023-04-25 · Modified: 2025-02-03
- Record: https://cvemate.com/vulnerability/CVE-2023-29012 · JSON: https://cvemate.com/vulnerability/CVE-2023-29012/json

## Description

```text
Git for Windows is the Windows port of Git. Prior to version 2.40.1, any user of Git CMD who starts the command in an untrusted directory is impacted by an Uncontrolles Search Path Element vulnerability. Maliciously-placed `doskey.exe` would be executed silently upon running Git CMD. The problem has been patched in Git for Windows v2.40.1. As a workaround, avoid using Git CMD or, if using Git CMD, avoid starting it in an untrusted directory.
```

## Signals

- CVSS: 7.8 high (v3.1, NVD) CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- EPSS: 0.38%, percentile 34.059%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected

- git\_for\_windows\_project git\_for\_windows: \< 2.40.1
- git-for-windows git: \< 2.40.1

## References

- <https://github.com/git-for-windows/git/security/advisories/GHSA-gq5x-v87v-8f7g>
- <https://github.com/git-for-windows/git/releases/tag/v2.40.1.windows.1>

---

Data as of 2026-12-05T03:06:54.587Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
