{"answers":{"affected":"2 open source packages ship an affected version, including repomix. It affects 1 product.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-49987 exists.","fix":"Upgrade repomix to 1.14.1 or later.","what":"CVE-2026-49987 is a high-severity command injection vulnerability in yamadashy repomix, published on 15 Jul 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2026-49987 and fix it if it is affected.\n\nWhat it is: CVE-2026-49987 is a high-severity command injection vulnerability in yamadashy repomix, published on 15 Jul 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-49987 exists.\n\nAffected packages and fixed versions:\n- repomix (npm): affected all versions; fixed in 1.14.1\n- repomix (npm): affected all versions; fixed in 1.14.1\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2026-49987/ (Markdown: https://insights.sbomify.com/CVE-2026-49987/index.md)","id":"CVE-2026-49987","markdown":"https://insights.sbomify.com/CVE-2026-49987/index.md","name":"CVE-2026-49987","record":{"aliases":["GHSA-9mm9-rqhj-j5mx"],"analysis":{"component_type":"developer_tool","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"yes","non_default_config":false,"product_category":"Repository packing tool","requires_auth":"none","summary":"Attackers can execute arbitrary commands by injecting Git options via the remote branch argument in Repomix.","user_interaction":"required","vuln_class":"command_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[{"product":"repomix","vendor":"yamadashy"}],"cvss":{"score":7.5,"severity":"high","source":"cna","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","version":"4.0"},"cwes":[{"id":"CWE-88","name":"Improper Neutralization of Argument Delimiters in a Command"}],"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.","ecosystems":["npm"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"Repomix: Command Injection (RCE) via `--remote-branch` Argument Injection","id":"CVE-2026-49987","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"npm","product":null,"products":[],"type":"command_injection","year":"2026"},"n_packages":2,"n_references":3,"next":{"headline":"Repomix: attach_packed_output can bypass file-read secret scanning for supported local files","id":"CVE-2026-49988"},"packages":[{"ecosystem":"npm","fixed":["1.14.1"],"introduced":["0"],"last_affected":[],"package":"repomix","purl":null,"source":"GHSA-9mm9-rqhj-j5mx"},{"ecosystem":"npm","fixed":["1.14.1"],"introduced":["0"],"last_affected":[],"package":"repomix","purl":"pkg:npm/repomix","source":"GHSA-9mm9-rqhj-j5mx"}],"prev":{"headline":"Cortex has Untrusted Project Bootstrap Code Execution via `CLAUDE_PROJECT_DIR`","id":"CVE-2026-49986"},"products":["repomix"],"published":"2026-07-15","related":[{"cvss_score":6.8,"headline":"Repomix: attach_packed_output can bypass file-read secret scanning for supported local files","id":"CVE-2026-49988","kev_date_added":null,"published":"2026-07-15"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"total"},"state":"PUBLISHED","updated":"2026-07-15","vendors":["yamadashy"]},"summary":"Attackers can execute arbitrary commands by injecting Git options via the remote branch argument in Repomix.","url":"https://insights.sbomify.com/CVE-2026-49987/"}