# CVE-2022-25866: Command Injection

- Severity: High 8.1 (CVSS:3.1, scored by snyk) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 3.65%, higher than 89% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-04-25T17:10:10.912Z
- Modified: 2026-09-10T03:49:17.899Z
- Also known as: GHSA-3xpw-vhmv-cw7h, SNYK-PHP-CZPROJECTGITPHP-2421349
- Weaknesses: CWE-74, CWE-77, CWE-88
- Assigned by: snyk

## Description

The package czproject/git-php before 4.0.3 are vulnerable to Command Injection via git argument injection. When calling the isRemoteUrlReadable($url, array $refs = NULL) function, both the url and refs parameters are passed to the git ls-remote subcommand in a way that additional flags can be set. The additional flags can be used to perform a command injection.

(As written by CVE List.)

## Affected

- czproject/git-php: from unspecified before 4.0.3
- czproject/git-php (Packagist): before 4.0.3
- git-php_project git-php: before 4.0.3

## Every score

- snyk: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P`
- GitHub: CVSS:3.1 8.1 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 7.5 High `AV:N/AC:L/Au:N/C:P/I:P/A:P`

## References

- <https://snyk.io/vuln/SNYK-PHP-CZPROJECTGITPHP-2421349> (exploit, patch, third-party-advisory, web)
- <https://github.com/czproject/git-php/commit/5e82d5479da5f16d37a915de4ec55e1ac78de733> (patch, third-party-advisory, web)
- <https://github.com/czproject/git-php/releases/tag/v4.0.3> (release-notes, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-25866> (advisory)
- <https://github.com/czproject/git-php> (package)

## Sources

- CVE List: [CVE-2022-25866](https://www.cve.org/CVERecord?id=CVE-2022-25866), CVE Terms of Use, modified 2024-09-16
- GitHub Advisory Database: [GHSA-3xpw-vhmv-cw7h](https://github.com/advisories/GHSA-3xpw-vhmv-cw7h), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2022-25866](https://nvd.nist.gov/vuln/detail/CVE-2022-25866), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-25866 · Whole record: https://cve.day/CVE-2022-25866.json · Rebuilt by cve.day 2026-11-25T22:58:11.239Z
