PHP denial of service in folded HTTP response header parsing
PHP Group PHP
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| PHP Group PHP |
| No fix yet |
Original description
Denial of service through folded HTTP response headers.
The HTTP stream wrapper joins each continuation line of a folded response header to the accumulated value by allocating a new string and copying the whole value, so a response with many short continuation lines takes disproportionate CPU time to parse. An attacker who controls an HTTP or HTTPS response fetched through file_get_contents(), fopen() or other stream functions, by making the application request a chosen URL or by influencing a server it already contacts, can keep PHP workers busy. Repeated or concurrent requests can cause a denial of service.