Advisory

GHSA-v9qv-c7wm-wgmf

Also known as: BIT-composer-2024-35242, CVE-2024-35242

Summary

Composer has multiple command injections via malicious git/hg branch names

Details

Impact

The composer install command running inside a git/hg repository which has specially crafted branch names can lead to command injection. So this requires cloning untrusted repositories.

Patches

2.2.24 for 2.2 LTS or 2.7.7 for mainline

Workarounds

Avoid cloning potentially compromised repositories.

Severity

High Basis: The source's own band: HIGH

Dates

Published
2024-06-10 21:36 UTC
Modified
2026-09-10 03:50 UTC

Affected packages and fixes

composer/composer

Packagist · All systems

Affected

  • introduced 2.0, fixed 2.2.24 (ecosystem)

Fixed versions

2.2.24

Fix

The export has no generic command for this ecosystem.

composer/composer

Packagist · All systems

Affected

  • introduced 2.3, fixed 2.7.7 (ecosystem)

Fixed versions

2.7.7

Fix

The export has no generic command for this ecosystem.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences