Cli server not responsive when responding with 422 http status code
| Bug #65066 | Cli server not responsive when responding with 422 http status code | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Submitted: | 2013-06-19 15:52 UTC | Modified: | 2013-06-20 19:19 UTC |
|
||||||||||
| From: | mauroasprea+php at gmail dot com | Assigned: | aharvey (profile) | |||||||||||
| Status: | Closed | Package: | Built-in web server | |||||||||||
| PHP Version: | 5.4.16 | OS: | ||||||||||||
| Private report: | No | CVE-ID: | None | |||||||||||
[2013-06-19 15:52 UTC] mauroasprea+php at gmail dot com
Description: ------------ If u save and run the test script sample below with the cli built in server: php -S localhos:8000 -t . Then when browsing to the file, the page never responds back (timeouts) I've taken a look at the php cli server sourced and it seems that there a lot of missing http status codes, see https://github.com/php/php- src/blob/master/sapi/cli/php_cli_server.c#L207 So it seems that there's an endless loop here https://github.com/php/php-src/blob/master/sapi/cli/php_cli_server.c#L345 Test script: --------------- <?php http_response_code(422); echo 'Not being shown!'; Expected result: ---------------- The script should show the page with the text: Not being shown! And the http status code "422" Actual result: -------------- Fatal error: Maximum execution time of 30 seconds exceeded in Unknown on line 0 Seems to be endless loop
Patches
Pull Requests
History
AllCommentsChangesGit/SVN commits
[2013-06-19 15:55 UTC] mauroasprea+php at gmail dot com
[2013-06-19 18:23 UTC] aharvey@php.net
-Package: CGI/CLI related +Package: Built-in web server -Assigned To: +Assigned To: aharvey
[2013-10-03 20:39 UTC] clyde dot adams at mailismagic dot com
[2013-10-03 20:39 UTC] clyde dot adams at mailismagic dot com
[2013-10-03 20:39 UTC] clyde dot adams at mailismagic dot com