High severityNVD Advisory· Published Jul 15, 2026· Updated Jul 15, 2026
Repomix: Command Injection (RCE) via `--remote-branch` Argument Injection
CVE-2026-49987
Description
Repomix is a tool that packs repositories into AI-friendly files. Prior to 1.14.1, src/core/git/gitCommand.ts execGitShallowClone passes the --remote-branch value directly to git fetch and git checkout without validation or --end-of-options, allowing --upload-pack or other Git option injection that bypasses validateGitUrl() dangerous parameter checks and can execute commands through local or SSH-style transports. This issue is fixed in version 1.14.1.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
repomixnpm | < 1.14.1 | 1.14.1 |
Affected products
1Patches
Vulnerability mechanics
References
4- github.com/advisories/GHSA-9mm9-rqhj-j5mxghsaADVISORY
- github.com/yamadashy/repomix/commit/92bfa3193b5233a0d21beff929444153c088de82mitrex_refsource_MISC
- github.com/yamadashy/repomix/releases/tag/v1.14.1mitrex_refsource_MISC
- github.com/yamadashy/repomix/security/advisories/GHSA-9mm9-rqhj-j5mxghsax_refsource_CONFIRMWEB
News mentions
0No linked articles in our index yet.