CVE-2007-1522

PHP 5.2.0-5.2.1 - Remote Code Execution via Session Identifier Double Free

Title source: llm
STIX 2.1

Exploitation Summary

EIP tracks 1 public exploit for CVE-2007-1522. PoCs published by Stefan Esser.

AI-analyzed exploit summary This exploit targets a double-free vulnerability in PHP 5's session handling (CVE-2007-1522) to achieve remote code execution via a bindshell. It uses heap manipulation and a custom error handler to overwrite memory addresses with shellcode.

Description

Double free vulnerability in the session extension in PHP 5.2.0 and 5.2.1 allows context-dependent attackers to execute arbitrary code via illegal characters in a session identifier, which is rejected by an internal session storage module, which calls the session identifier generator with an improper environment, leading to code execution when the generator is interrupted, as demonstrated by triggering a memory limit violation or certain PHP errors.

Exploits (1)

exploitdb WORKING POC VERIFIED
by Stefan Esser · phplocallinux
https://www.exploit-db.com/exploits/3480

This exploit targets a double-free vulnerability in PHP 5's session handling (CVE-2007-1522) to achieve remote code execution via a bindshell. It uses heap manipulation and a custom error handler to overwrite memory addresses with shellcode.

Classification
Working Poc 95%
Attack Type
Rce
Complexity
Complex
Reliability
Racy
Target: PHP 5.2.0 and later
No auth needed
Prerequisites: PHP 5.2.0 or later with session support enabled
devstral-2 · analyzed Feb 16, 2026 Full analysis →

References (6)

Core 6
Core References
Third Party Advisory vdb-entry x_refsource_vupen
http://www.vupen.com/english/advisories/2007/0960
Third Party Advisory third-party-advisory x_refsource_secunia
http://secunia.com/advisories/25056
Third Party Advisory third-party-advisory x_refsource_secunia
http://secunia.com/advisories/24505
Exploit, Vendor Advisory x_refsource_misc
http://www.php-security.org/MOPB/MOPB-23-2007.html
Third Party Advisory, VDB Entry vdb-entry x_refsource_bid
http://www.securityfocus.com/bid/22971
Vendor Advisory vendor-advisory x_refsource_suse
http://www.novell.com/linux/security/advisories/2007_32_php.html

Scores

EPSS 0.0661
EPSS Percentile 93.0%

Details

Status published
Products (2)
php/php 5.2.0
php/php 5.2.1
Published Mar 20, 2007
Tracked Since Feb 18, 2026