CVE-2024-24821
Last modified
CVE-2024-24821 is a high-severity vulnerability rated 7.8/10 on the CVSS scale. Composer is a dependency Manager for the PHP language. In affected versions several files within the local working directory are included during the invocation of Composer and in the context of the executing user. EPSS estimates a 0.27% chance of exploitation in the next 30 days.
Description
Composer is a dependency Manager for the PHP language. In affected versions several files within the local working directory are included during the invocation of Composer and in the context of the executing user. As such, under certain conditions arbitrary code execution may lead to local privilege escalation, provide lateral user movement or malicious code execution when Composer is invoked within a directory with tampered files. All Composer CLI commands are affected, including composer.phar's self-update. The following scenarios are of high risk: Composer being run with sudo, Pipelines which may execute Composer on untrusted projects, Shared environments with developers who run Composer individually on the same project. This vulnerability has been addressed in versions 2.7.0 and 2.2.23. It is advised that the patched versions are applied at the earliest convenience. Where not possible, the following should be addressed: Remove all sudo composer privileges for all users to mitigate root privilege escalation, and avoid running Composer within an untrusted directory, or if needed, verify that the contents of `vendor/composer/InstalledVersions.php` and `vendor/composer/installed.php` do not include untrusted code. A reset can also be done on these files by the following:```sh rm vendor/composer/installed.php vendor/composer/InstalledVersions.php composer install --no-scripts --no-plugins ```
Metrics
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Weakness Enumeration
Affected Software
| Vendor | Product | Versions |
|---|---|---|
| Getcomposer | Composer | >= 2.0.0, < 2.2.23 |
| Getcomposer | Composer | >= 2.3.0, < 2.7.0 |
References
- https://github.com/composer/composer/security/advisories/GHSA-7c6p-848j-wh5hThird Party Advisory
- https://github.com/composer/composer/security/advisories/GHSA-7c6p-848j-wh5hThird Party Advisory
Timeline
- Published
- Last Modified
- Status
- Modified
Frequently Asked Questions
What is CVE-2024-24821?
How severe is CVE-2024-24821?
How do I fix CVE-2024-24821?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2024
- CVE-2024-24816CKEditor4 is an open source what-you-see-is-what-you-get HTM…6.1
- CVE-2024-24817Discourse Calendar adds the ability to create a dynamic cale…5.3
- CVE-2024-24818EspoCRM is an Open Source Customer Relationship Management s…5.9
- CVE-2024-24819icingaweb2-module-incubator is a working project of bleeding…8.8
- CVE-2024-2482A vulnerability has been found in Surya2Developer Hostel Man…3.7
- CVE-2024-24820Icinga Director is a tool designed to make Icinga 2 configur…8.3
- CVE-2024-24822Pimcore's Admin Classic Bundle provides a backend user inter…9.1
- CVE-2024-24823Graylog is a free and open log management platform. Starting…4.4
- CVE-2024-24824Graylog is a free and open log management platform. Starting…8.8
- CVE-2024-24825DIRAC is a distributed resource framework. In affected versi…7.5
- CVE-2024-24826Exiv2 is a command-line utility and C++ library for reading,…5
- CVE-2024-24827Discourse is an open source platform for community discussio…7.5
Are you affected by CVE-2024-24821?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
