Read the docs

OS command injection in git-diff via gitDiff input strings

Priority MEDIUM 53CWE-78Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
Low
Attack requirements
None
Impact type
Code execution
Confidentiality · integrity · availability
High · High · High
Fix status
Fixed

Attack profile from CVSS 4.0 · CNA. Fix status from CNA and GitHub. Impact type from CWE-78.

Summary

git-diff before 2.0.7 contains an OS command injection flaw (CWE-78) in its gitDiff API. An unauthenticated remote attacker who controls a diffed document string can embed $(cmd) or backtick substitutions that are evaluated by shelljs.exec, running commands with Node.js process privileges.

Written with Claude Haiku 5.5 from the sources below · 2026-10-28

Description from the CNA

git-diff before 2.0.7 contains an OS command injection vulnerability that allows attackers to execute shell commands by supplying crafted strings to the gitDiff API. Attackers who control a diffed document string can embed $(cmd) or backtick substitutions that shelljs.exec evaluates, running commands with Node.js process privileges.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.02348 83rd percentileScored 2026-11-07
Fix Fixed git-diff (danday74): 2.0.7git-diff (npm): 2.0.7

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
Yes
Technical impact
Total

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
danday74git-diffbefore 2.0.72.0.7Patch availableCNA
—git-diff (npm)before 2.0.72.0.7Patch availableGHSA-6wfj-92cw-88vg
  • git-diff Vendordanday74 Affected before 2.0.7 Fixed in 2.0.7 Patch available CNA
  • git-diff (npm) Vendor— Affected before 2.0.7 Fixed in 2.0.7 Patch available GHSA-6wfj-92cw-88vg

Remediation

Update git-diff to version 2.0.7, which fixes the flaw in the npm package git-diff. The sources list no further fixed version for git-diff.

Written with Claude Haiku 5.5 from the sources below · 2026-10-28

  • Fix · CNA git-diff (danday74) Fixed in 2.0.7
  • Fix · GHSA-6wfj-92cw-88vg git-diff (npm) Fixed in 2.0.7 Advisory →

Timeline

  1. 2026-10-14 Threatist record created from CVE-2026-110634
  2. 2026-10-14 Alias added: GHSA-6wfj-92cw-88vg
  3. 2026-10-15 CISA SSVC decision points changed

References

Sources