Skip to content

fedora

Composer vulnerable to command injection via malicious git/hg branch names

CVE-2024-35242Published 10 Jun 2024, 21:23 UTC

Real-world risk

6.0/ 10Medium

Schedule in the normal cycle

PreliminaryFrom the CVSS vector only · confidence low

CVSS

8.8

scored by the vendor (CNA), CVSS 3.1

In plain words

No plain-language summary yet. The original description is below.

Original description (from GitHub_M)

Composer is a dependency manager for PHP. On the 2.x branch prior to versions 2.2.24 and 2.7.7, the `composer install` command running inside a git/hg repository which has specially crafted branch names can lead to command injection. This requires cloning untrusted repositories. Patches are available in version 2.2.24 for 2.2 LTS or 2.7.7 for mainline. As a workaround, avoid cloning potentially compromised repositories.

Am I affected?

ProductAffected versions (from the sources)Fixed in
fedoraCommon= 39; = 40—
composerNiche>= 2.0, < 2.2.24; >= 2.3, < 2.7.72.2.24, 2.7.7
composerNiche>= 2.0, < 2.2.24; >= 2.3, < 2.7.72.2.24, 2.7.7

What to do

Update to a fixed version: 2.2.24, 2.7.7.

Why this score

FactorValueEvidence×
ImpactFull compromiseCode execution or full control of the system or applicationFrom the CVSS vector1.00
Attacker positionInternetAnyone on the Internet can reach a typical deploymentFrom the CVSS vector1.00
Privileges neededNoneNo accountFrom the CVSS vector1.00
Victim interactionRoutineA normal action: open a file, visit a page, click a linkFrom the CVSS vector0.70
ConfigurationDefaultOut-of-the-box installs are vulnerableFrom the CVSS vector1.00
ReliabilityReliableDeterministic: injection, logic bug, path traversalFrom the CVSS vector1.00

Threat level T1: Nothing known (× 0.85)

The default for a new disclosure

EPSS 3.3% chance of exploitation in 30 days (percentile 89), as of 2026-12-03.

The arithmetic
  1. Prerequisites multiplied together0.700
  2. Threat T1: Nothing known0.850
  3. 10 × impact 1 × prerequisites 0.7 × threat 0.855.950
  4. Rounded to one decimal between 0.1 and 106.0

How the score works

Exploitation and evidence timeline

  1. 10 Jun 2024 Published
  2. 3 Dec 2026 Risk 6.0 (cvss fallback)

Weakness

CWE-77

References

Get alerts for fedora

Free email or text alerts when a vulnerability in fedora reaches risk 8 or higher. Nothing else.