-
CVSS Score
-| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| composer/composer | composer | >= 2.0, < 2.2.24 | 2.2.24 |
| composer/composer | composer | >= 2.3, < 2.7.7 | 2.7.7 |
The vulnerability stemmed from how VersionGuesser.php handled SCM commands. The pre-patch code passed command templates as strings ('git rev-list %candidate%..%branch%') to guessFeatureVersion(), which used string replacement to insert branch names. This allowed injection via specially crafted branch names. The patch changed $scmCmdline to an array of arguments, preventing command concatenation. The function signature change from string to array in guessFeatureVersion() and the accompanying test fixes confirm this was the injection vector.
A Semantic Attack on Google Gemini - Read the Latest Research