Two RCEs, one Wednesday: responsible disclosure has run out of time
A leaked PHP core remote code execution chain (php2shell) was exploited in the wild before its patch, and the author describes how a virtual patch keyed on the multipart upload-progress field name blocked working exploit tools within minutes. The same post also covers a Brotli decoder flaw in Node.js whose fix had sat unreleased in a public repository for months.
Published on blog.sicuranext.com
Responsible disclosure is a deal about time. The researcher stays quiet, the vendor ships a fix, and on an agreed day the advisory and the patch go out together, so defenders start the race at the same moment as attackers.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely a heap use-after-free in PHP's session upload-progress callback combined with stale global state in persistent workers, reachable through multipart parsing before any application code runs.
Impact
Attackers could run a command that harvests .env secrets, though the public tool relies on a hardcoded pointer that only lands on builds without ASLR or PIE, and the described rule blocked every attempt seen.
What the attacker needed
No authentication; target runs PHP 5.4 or newer; attacker sends crafted multipart POST; build without ASLR or PIE for the blind tool
The fix
A virtual patch blocking any multipart part named PHP_SESSION_UPLOAD_PROGRESS was deployed before the vendor release, and official fixes shipped for PHP 8.2 and newer.
How it was found
- Send a multipart POST containing a session ID field matching the cookie
- Include a field named PHP_SESSION_UPLOAD_PROGRESS to arm the vulnerable callback
- Send a file part with chosen-size filler bytes to shape the heap
- Spray many copies of a forged internal structure in an array field
- Trigger the out-of-memory condition through the large upload so the freed memory is reused
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
A remote code execution bug lets someone run their own commands on a server over the network, without logging in. Here, PHP's handling of file uploads could be tricked into running a command that reads a configuration file full of passwords and keys. The defenders blocked the requests by looking for one specific field name that every known attack tool has to send.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.