php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #66276 Missing HTTP headers on CORE_ERROR output of php54.cgi
Submitted: 2013-12-12 15:23 UTC Modified: 2013-12-12 19:23 UTC
Votes:5
Avg. Score:4.4 ± 0.8
Reproduced:4 of 5 (80.0%)
Same Version:2 (50.0%)
Same OS:4 (100.0%)
From: dave at icdsoft dot com Assigned:
Status: Open Package: CGI/CLI related
PHP Version: 5.4.22 OS: Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2013-12-12 15:23 UTC] dave at icdsoft dot com
Description:
------------
The error handling of php54.cgi does not submit HTTP headers in some cases. This causes Internal Server Error 500 in Apache.

$ php54.cgi <test.php
<br />
<b>Fatal error</b>:  Directive 'magic_quotes_gpc' is no longer available in PHP in <b>Unknown</b> on line <b>0</b><br />

For other errors the headers are ok

$ php54.cgi <test.php
X-Powered-By: PHP/5.4.22
Content-type: text/html

<br />
<b>Parse error</b>:  syntax error, unexpected 'df' (T_STRING) in <b>-</b> on line <b>3</b><br />


Test script:
---------------
$ cat test.php
<?php
  phpinfo();  
?>

$ cat php.ini
register_globals = on


Expected result:
----------------
X-Powered-By: PHP/5.4.22
Content-type: text/html

<br />
<b>Fatal error</b>:  Directive 'magic_quotes_gpc' is no longer available in PHP in <b>Unknown</b> on line <b>0</b><br />

Actual result:
--------------
<br />
<b>Fatal error</b>:  Directive 'magic_quotes_gpc' is no longer available in PHP in <b>Unknown</b> on line <b>0</b><br />

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-12-12 19:23 UTC] aharvey@php.net
-Package: Apache related +Package: CGI/CLI related
 
PHP Copyright © 2001-2018 The PHP Group
All rights reserved.
Last updated: Wed Nov 14 11:01:25 2018 UTC