From: Jim Jagielski Date: Mon, 17 Sep 2007 16:48:30 +0000 (+0000) Subject: Merge r507526 from trunk: X-Git-Tag: 2.2.7~400 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=10402055f4e2eff6713988b66e86e0402875c430;p=thirdparty%2Fapache%2Fhttpd.git Merge r507526 from trunk: Return METHOD_NOT_ALLOWED, not FORBIDDEN, to a TRACE request when TraceEnable is Off. This agrees with our documentation, and with our Allow: header in response to OPTIONS. Submitted by: niq Reviewed by: jim git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@576514 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/STATUS b/STATUS index 34e52e4f251..80974fac7a8 100644 --- a/STATUS +++ b/STATUS @@ -79,14 +79,6 @@ RELEASE SHOWSTOPPERS: PATCHES ACCEPTED TO BACKPORT FROM TRUNK: [ start all new proposals below, under PATCHES PROPOSED. ] - * filters|proxy: Return METHOD_NOT_ALLOWED, not FORBIDDEN, to a TRACE - request when TraceEnable is Off. This agrees with our documentation, - and with our Allow: header in response to OPTIONS. - Trunk version of patch: - http://svn.apache.org/viewvc?view=rev&revision=507526 - Backport version for 2.2.x of patch: - Trunk version of patch works - +1: jim, niq, rpluem PATCHES PROPOSED TO BACKPORT FROM TRUNK: [ New proposals should be added at the end of the list ] diff --git a/modules/http/http_filters.c b/modules/http/http_filters.c index 85924054739..8d36e9215fc 100644 --- a/modules/http/http_filters.c +++ b/modules/http/http_filters.c @@ -832,7 +832,7 @@ AP_DECLARE_NONSTD(int) ap_send_http_trace(request_rec *r) if (conf->trace_enable == AP_TRACE_DISABLE) { apr_table_setn(r->notes, "error-notes", "TRACE denied by server configuration"); - return HTTP_FORBIDDEN; + return HTTP_METHOD_NOT_ALLOWED; } if (conf->trace_enable == AP_TRACE_EXTENDED) diff --git a/modules/proxy/mod_proxy.c b/modules/proxy/mod_proxy.c index 58798c4a006..0749a7eb729 100644 --- a/modules/proxy/mod_proxy.c +++ b/modules/proxy/mod_proxy.c @@ -708,7 +708,7 @@ static int proxy_handler(request_rec *r) apr_table_setn(r->notes, "verbose-error-to", "*"); ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, "proxy: TRACE forbidden by server configuration"); - return HTTP_FORBIDDEN; + return HTTP_METHOD_NOT_ALLOWED; } /* Can't test ap_should_client_block, we aren't ready to send