diff options
author | William A. Rowe Jr <wrowe@apache.org> | 2016-08-18 09:15:24 +0200 |
---|---|---|
committer | William A. Rowe Jr <wrowe@apache.org> | 2016-08-18 09:15:24 +0200 |
commit | 194e79fd412a6fe902cf04d3a1a69eadab1d3696 (patch) | |
tree | 4129dfc320a3a8b93432d8cc5de1c3f4e60d2d79 /docs/manual/mod/core.html.en | |
parent | Perform correct, strict parsing of the request line, handling the (diff) | |
download | apache2-194e79fd412a6fe902cf04d3a1a69eadab1d3696.tar.xz apache2-194e79fd412a6fe902cf04d3a1a69eadab1d3696.zip |
Docs regen
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1756730 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'docs/manual/mod/core.html.en')
-rw-r--r-- | docs/manual/mod/core.html.en | 123 |
1 files changed, 74 insertions, 49 deletions
diff --git a/docs/manual/mod/core.html.en b/docs/manual/mod/core.html.en index adb557e3ac..24d1976d33 100644 --- a/docs/manual/mod/core.html.en +++ b/docs/manual/mod/core.html.en @@ -61,7 +61,6 @@ available</td></tr> <li><img alt="" src="../images/down.gif" /> <a href="#elseif"><ElseIf></a></li> <li><img alt="" src="../images/down.gif" /> <a href="#enablemmap">EnableMMAP</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#enablesendfile">EnableSendfile</a></li> -<li><img alt="" src="../images/down.gif" /> <a href="#enforcehttpprotocol">EnforceHTTPProtocol</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#error">Error</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#errordocument">ErrorDocument</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#errorlog">ErrorLog</a></li> @@ -73,6 +72,7 @@ available</td></tr> <li><img alt="" src="../images/down.gif" /> <a href="#forcetype">ForceType</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#gprofdir">GprofDir</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#hostnamelookups">HostnameLookups</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#httpprotocoloptions">HTTPProtocolOptions</a></li> <li><img alt="" src="../images/down.gif" /> <a href="#if"><If></a></li> <li><img alt="" src="../images/down.gif" /> <a href="#ifdefine"><IfDefine></a></li> <li><img alt="" src="../images/down.gif" /> <a href="#ifmodule"><IfModule></a></li> @@ -1301,54 +1301,6 @@ version 2.3.9.</td></tr> </div> <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> -<div class="directive-section"><h2><a name="EnforceHTTPProtocol" id="EnforceHTTPProtocol">EnforceHTTPProtocol</a> <a name="enforcehttpprotocol" id="enforcehttpprotocol">Directive</a></h2> -<table class="directive"> -<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Modify restrictions on HTTP Request Messages</td></tr> -<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>EnforceHTTPProtocol [Strict|Unsafe] [Allow0.9|Require1.0]</code></td></tr> -<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>EnforceHTTPProtocol Strict Allow0.9</code></td></tr> -<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr> -<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr> -<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr> -<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>2.2.32 or 2.4.24 and later</td></tr> -</table> - <p>This directive changes the rules applied to the HTTP Request Line - (<a href="https://tools.ietf.org/html/rfc7230#section-3.1.1">RFC 7230 §3.1.1</a>) and the HTTP Request Header Fields - (<a href="https://tools.ietf.org/html/rfc7230#section-3.2">RFC 7230 §3.2</a>), which are now applied by default or using - the <code>Strict</code> option. Due to legacy modules, applications or - custom user-agents which must be deperecated, an <code>Unsafe</code> - option has been added to revert to the legacy behavior. These rules are - applied prior to request processing, so must be configured at the global - or default (first) matching virtual host section, by interface and not - by name, to be honored.</p> - - <p>Prior to the introduction of this directive, the Apache HTTP Server - request message parsers were tolerant of a number of forms of input - which did not conform to the protocol. - <a href="https://tools.ietf.org/html/rfc7230#section-9.4">RFC 7230 §9.4 Request Splitting</a> and - <a href="https://tools.ietf.org/html/rfc7230#section-9.5">§9.5 Response Smuggling</a> call out only two of the potential - risks of accepting non-conformant request messages. As of the introduction - of this directive, all grammer rules of the specification are enforced in - the <code>Strict</code> operating mode.</p> - - <p>Users are strongly cautioned against toggling the <code>Unsafe</code> - mode of operation for these reasons, most especially on outward-facing, - publicly accessible server deployments. Reviewing the messages within the - <code class="directive">ErrorLog</code> in the <code>info</code> - <code class="directive">LogLevel</code> or below can help identify such faulty - requests, along with their origin. Users should pay particular attention - to any 400 responses in the access log for indiciations that these requests - are being correctly rejected.</p> - - <p><a href="https://tools.ietf.org/html/rfc2616#section-19.6">RFC 2616 §19.6</a> "Compatibility With Previous Versions" had - encouraged HTTP servers to support legacy HTTP/0.9 requests. RFC 7230 - superceeds this with "The expectation to support HTTP/0.9 requests has - been removed" and offers additional comments in - <a href="https://tools.ietf.org/html/rfc7230#appendix-A">RFC 2616 Appendix A</a>. The <code>Require1.0</code> option allows - the user to remove support of the <code>Allow0.9</code> default option's - behavior.</p> - -</div> -<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> <div class="directive-section"><h2><a name="Error" id="Error">Error</a> <a name="error" id="error">Directive</a></h2> <table class="directive"> <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Abort configuration parsing with a custom error message</td></tr> @@ -2075,6 +2027,79 @@ media type in the HTTP Content-Type header field</td></tr> </div> <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="directive-section"><h2><a name="HTTPProtocolOptions" id="HTTPProtocolOptions">HTTPProtocolOptions</a> <a name="httpprotocoloptions" id="httpprotocoloptions">Directive</a></h2> +<table class="directive"> +<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Modify restrictions on HTTP Request Messages</td></tr> +<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>HTTPProtocolOptions [Strict|Unsafe] [Allow0.9|Require1.0] +[StrictWhitespace|LenientWhitespace] [RegisteredMethods|LenientMethods]</code></td></tr> +<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>HTTPProtocolOptions Strict Allow0.9 LenientWhitespace +LenientMethods</code></td></tr> +<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr> +<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr> +<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>core</td></tr> +<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>2.2.32 or 2.4.24 and later</td></tr> +</table> + <p>This directive changes the rules applied to the HTTP Request Line + (<a href="https://tools.ietf.org/html/rfc7230#section-3.1.1">RFC 7230 §3.1.1</a>) and the HTTP Request Header Fields + (<a href="https://tools.ietf.org/html/rfc7230#section-3.2">RFC 7230 §3.2</a>), which are now applied by default or using + the <code>Strict</code> option. Due to legacy modules, applications or + custom user-agents which must be deperecated, an <code>Unsafe</code> + option has been added to revert to the legacy behavior. These rules are + applied prior to request processing, so must be configured at the global + or default (first) matching virtual host section, by interface and not + by name, to be honored.</p> + + <p>Prior to the introduction of this directive, the Apache HTTP Server + request message parsers were tolerant of a number of forms of input + which did not conform to the protocol. + <a href="https://tools.ietf.org/html/rfc7230#section-9.4">RFC 7230 §9.4 Request Splitting</a> and + <a href="https://tools.ietf.org/html/rfc7230#section-9.5">§9.5 Response Smuggling</a> call out only two of the potential + risks of accepting non-conformant request messages. As of the introduction + of this directive, all grammer rules of the specification are enforced in + the default <code>Strict</code> operating mode.</p> + + <p>Users are strongly cautioned against toggling the <code>Unsafe</code> + mode of operation for these reasons, most especially on outward-facing, + publicly accessible server deployments. Reviewing the messages within the + <code class="directive">ErrorLog</code>, configured with + <code class="directive">LogLevel</code> <code>info</code> level or below, + can help identify such faulty requests along with their origin. + Users should pay particular attention to any 400 responses in the access + log for indiciations that valid requests are unexpectedly rejected.</p> + + <p><a href="https://tools.ietf.org/html/rfc2616#section-19.6">RFC 2616 §19.6</a> "Compatibility With Previous Versions" had + encouraged HTTP servers to support legacy HTTP/0.9 requests. RFC 7230 + superceeds this with "The expectation to support HTTP/0.9 requests has + been removed" and offers additional comments in + <a href="https://tools.ietf.org/html/rfc7230#appendix-A">RFC 2616 Appendix A</a>. The <code>Require1.0</code> option allows + the user to remove support of the default <code>Allow0.9</code> option's + behavior.</p> + + <p><a href="https://tools.ietf.org/html/rfc7230#section-3.5">RFC 7230 §3.5</a> "Message Parsing Robustness" permits, and + identifies potential risks of parsing messages containing non-space + character whitespace. While the spec defines that exactly one space + seperates the URI from the method, and the protocol from the URI, the + Apache HTTP Server has traditionally been lenient in accepting other + whitespace including one or more horizontal-tab or space characters. + The default <code>LenientWhitespace</code> continues to accept such + requests from non-conforming user-agents, but the administrator may toggle + the <code>StrictWhitespace</code> option to insist on precisely two spaces + in the request line. Other whitespace including vertical-tab, form-feed, + and carriage-return characters are rejected and cannot be supported.</p> + + <p><a href="https://tools.ietf.org/html/rfc7231#section-4.1">RFC 7231 §4.1</a> "Request Methods" "Overview" requires that + origin servers shall respond with an error when an unsupported method + is encountered in the request line. This already happens when the + <code>LenientMethods</code> option is used, but administrators may wish + to toggle the <code>RegisteredMethods</code> option and register all + permitted method tokens using the <code class="directive">RegisterHttpMethod</code> + directive, particularly if the <code>Unsafe</code> option has been toggled. + The <code>RegisteredMethods</code> option should <strong>not</strong> + be toggled for forward proxy hosts, as the methods supported by the + origin servers are unknown to the proxy server.</p> + +</div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> <div class="directive-section"><h2><a name="If" id="If"><If></a> <a name="if" id="if">Directive</a></h2> <table class="directive"> <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Contains directives that apply only if a condition is |