#14409 [Com]: request for nonexistent file does not return 404 error

From: Date: Wed, 31 Jul 2002 13:01:16 +0000
Subject: #14409 [Com]: request for nonexistent file does not return 404 error
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-15664@lists.php.net to get a copy of this message
ID: 14409 Comment by: phil@lchost.nospam.co.uk Reported By: support@teamITS.com Status: Open Bug Type: Apache related Operating System: IRIX64 vega 6.5 04191225 IP27 PHP Version: 4.1.2 New Comment: Forgot to tell you that it's an i386 Architecture :) Previous Comments: ------------------------------------------------------------------------ [2002-07-31 09:00:03] phil@lchost.nospam.co.uk Same problem is occuring on Debian 3.0 Linux - worked fine (as a cgi) on the older version of Apache present in 2.2r7 - Only started 500 erroring instead of 404'ing when Apache 1.3.26 was installed as part of the upgrade. ------------------------------------------------------------------------ [2002-06-18 11:25:24] support@teamITS.com Note PHP version change from 4.0.6 to 4.1.2 (same issue). error_log entry: [Tue Jun 18 11:13:31 2002] [error] [client 64.81.224.87] Premature end of script headers: /u/httpd/cgi-bin/php4.cgi Interesting note, however...the problem does occur now on IIS/PHP 4.1.2 - "CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:" (there the error ends). ------------------------------------------------------------------------ [2002-06-18 04:04:26] derick@php.net Please show us the lines in the apache log file of such an request. Derick ------------------------------------------------------------------------ [2001-12-19 11:34:46] support@teamITS.com To clarify the comment about IIS, PHP is installed as a CGI (php.exe) on that server. ------------------------------------------------------------------------ [2001-12-10 14:38:30] support@teamITS.com To reproduce, enter a bogus filename in a browser. For example, http://www.teamITS.com/blahblah.php. The server returns an Internal Server Error rather than a 404 (page not found) error. I reported this to Apache and their response was: "This is the way the appropriate directives work on purpose (although you didn't say just how you had PHP configured to run), since it is possible to create a virtual URL space. The PHP module is the one deciding how to handle requests for nonexisting files." Their issue number was mod_cgi/8683 (as PHP is installed as a CGI module on this server). Sounds to me like they are saying PHP should be returning an error to Apache. If you want more info on the PHP setup on our server, browse to: http://www.teamits.com/phpinfo.php Note that a PHP/IIS4 combination does return a 404 error. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=14409&edit=1

« previous php.bugs (#15664) next »