>Number: 2232 >Category: general >Synopsis: When using Error_document directives, Apache returns HTTP code >200 instead of the error code >Confidential: no >Severity: non-critical >Priority: medium >Responsible: apache >State: open >Class: sw-bug >Submitter-Id: apache >Arrival-Date: Fri May 15 06:50:00 PDT 1998 >Last-Modified: >Originator: [EMAIL PROTECTED] >Organization: apache >Release: 1.2.6 >Environment: Operating system: Digital Unix 4.0b (OSF1 tif.inria.fr V4.0 564 alpha) Compiler: gcc-2.7.2 >Description: I use Error_document for handling "not found" requests : ErrorDocument 404 /cgi-bin/notfound
When a such error occurs, Apache logs a 404 HTTP code in access.log, but it returns a code 200. This confuses a number of robots which consider the URL as valid. Apparently, this bug has been fixed un Apache-1.3b6. But it would be nice to have Apache-1.2.6 behave correctly... >How-To-Repeat: Here is a by-hand request to http://www-sor.inria.fr/cdhfsdfhsdfhsdfh : blake:~> telnet www-sor.inria.fr 80 Trying 128.93.11.73... Connected to tif.inria.fr. Escape character is '^]'. GET /cdhfsdfhsdfhsdfh HTTP/1.0 Host: www-sor.inria.fr HTTP/1.1 200 Date: Fri, 15 May 1998 13:46:40 GMT Server: Apache/1.2.6 Connection: close Content-Type: text/html <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> <HTML> <HEAD> <TITLE>Missing document!</TITLE> <BASE HREF="http://www-sor.inria.fr/"> </HEAD> <BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#551A8B"> [etc...] In the access.log file, we can see : blake.inria.fr - - [15/May/1998:15:46:48 +0200] "GET /cdhfsdfhsdfhsdfh HTTP/1.0" 404 3478 >Fix: >Audit-Trail: >Unformatted: [In order for any reply to be added to the PR database, ] [you need to include <[EMAIL PROTECTED]> in the Cc line ] [and leave the subject line UNCHANGED. This is not done] [automatically because of the potential for mail loops. ]
