CVE-2015-2171 — slim
Fix: slimphp/Slim@9fa6514CVE-2015-2171 is a Code Injection vulnerability in slim/slim. A fix is available for slim/slim — see the affected versions and patch details below.
Slim vulnerable to PHP object injection
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
Real-World Exposure
slim/slimReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.
Description
Middleware/SessionCookie.php in Slim before 2.6.0 allows remote attackers to conduct PHP object injection attacks and execute arbitrary PHP code via crafted session data.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | slim/slim | all versions | 2.6.0composer require slim/slim:^2.6.0 |
Affected Products
slimslimframeworkDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for slim/slim, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update slim/slim to 2.6.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2015-2171 is resolved across your whole dependency graph.
Workarounds
Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.
Frequently Asked Questions
Is CVE-2015-2171 in your dependencies?
Find it across Packagist, including transitive dependencies.