CVE-2022-25766
HIGH 8.8CVSS 3.1Command Injection in ungit
The package ungit before 1.5.20 are vulnerable to Remote Code Execution (RCE) via argument injection. The issue occurs when calling the /api/fetch endpoint. User controlled values (remote and ref) are passed to the git fetch command. By injecting some git options it was possible to get arbitrary command execution.
- Published
- 21 Mar 2022
- Last modified
- 8 Jul 2026
- Assigned by
- report@snyk.io
- NVD status
- Modified
- Weakness
- CWE-77CWE-88
- Also known as
- GHSA-hf8c-xr89-vfm5SNYK-JS-UNGIT-2414099
- Sources
- NVDJSONOSV GHSA-hf8c-xr89-vfm5JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | report@snyk.io (Secondary) | CVSS 3.1 | HIGH 8.8 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | HIGH 8.8 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| OSV | GitHub | CVSS 3.1 | HIGH 8.8 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | nvd@nist.gov (Primary) | CVSS 2.0 | MEDIUM 6.5 | AV:N/AC:L/Au:S/C:P/I:P/A:P |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | ungit_project | ungitcpe:2.3:a:ungit_project:ungit:*:*:*:*:*:node.js:*:* |
< 1.5.20 | 1.5.20 |
| OSV | npm | ungit | < 1.5.20 | 1.5.20 |
References
- https://github.com/FredrikNoren/ungit/blob/master/CHANGELOG.md%231520 · Broken Link, Release Notes, Third Party Advisory, WEB
- https://github.com/FredrikNoren/ungit/pull/1510 · Exploit, Patch, Third Party Advisory, WEB
- https://snyk.io/vuln/SNYK-JS-UNGIT-2414099 · Release Notes, Third Party Advisory, WEB
- https://nvd.nist.gov/vuln/detail/CVE-2022-25766 · ADVISORY
- https://github.com/FredrikNoren/ungit/pull/1511 · WEB
- https://github.com/FredrikNoren/ungit · PACKAGE
History
- 25 Nov 2026 20:34 UTC · NVD: first stored (published 21 Mar 2022)
- 25 Nov 2026 20:11 UTC · OSV: first stored (published 22 Mar 2022)