Added RFC7230_LEGACY compliance mode as the default

Signed-off-by: Greg Wilkins <gregw@webtide.com>
This commit is contained in:
Greg Wilkins 2017-12-27 13:50:10 +01:00
parent 278b9b01c2
commit 30e9c84b33
3 changed files with 8 additions and 8 deletions

View File

@ -58,16 +58,16 @@ public enum HttpCompliance // TODO in Jetty-10 convert this enum to a class so t
/** The legacy RFC2616 support, which incorrectly excludes
* {@link HttpComplianceSection#RFC7230_3_2_4_NO_WS_AFTER_FIELD_NAME}, {@link HttpComplianceSection#RFC7230_3_2_FIELD_COLON}
*/
RFC2616(sectionsBySpec("RFC2616,-RFC7230_3_2_FIELD_COLON,-RFC7230_3_1_1_METHOD_CASE_SENSITIVE")),
RFC2616_LEGACY(sectionsBySpec("RFC2616,-RFC7230_3_2_FIELD_COLON,-RFC7230_3_1_1_METHOD_CASE_SENSITIVE")),
/** The strict RFC2616 support mode */
RFC2616_STRICT(sectionsBySpec("RFC2616")),
RFC2616(sectionsBySpec("RFC2616")),
/** Jetty's current RFC7230 support, which incorrectly excludes {@link HttpComplianceSection#RFC7230_3_1_1_METHOD_CASE_SENSITIVE} */
RFC7230(sectionsBySpec("RFC7230,-RFC7230_3_1_1_METHOD_CASE_SENSITIVE")),
RFC7230_LEGACY(sectionsBySpec("RFC7230,-RFC7230_3_1_1_METHOD_CASE_SENSITIVE")),
/** The strict RFC7230 support mode */
RFC7230_STRICT(sectionsBySpec("RFC7230")),
/** The RFC7230 support mode */
RFC7230(sectionsBySpec("RFC7230")),
/** Custom compliance mode that can be defined with System property <code>org.eclipse.jetty.http.HttpCompliance.CUSTOM0</code> */
CUSTOM0(sectionsByProperty("CUSTOM0")),

View File

@ -29,7 +29,7 @@
<Item>
<New class="org.eclipse.jetty.server.HttpConnectionFactory">
<Arg name="config"><Ref refid="httpConfig" /></Arg>
<Arg name="compliance"><Call class="org.eclipse.jetty.http.HttpCompliance" name="valueOf"><Arg><Property name="jetty.http.compliance" default="RFC7230"/></Arg></Call></Arg>
<Arg name="compliance"><Call class="org.eclipse.jetty.http.HttpCompliance" name="valueOf"><Arg><Property name="jetty.http.compliance" default="RFC7230_LEGACY"/></Arg></Call></Arg>
</New>
</Item>
</Array>

View File

@ -46,5 +46,5 @@ etc/jetty-http.xml
## Connect Timeout in milliseconds
# jetty.http.connectTimeout=15000
## HTTP Compliance: RFC7230, RFC2616, LEGACY
# jetty.http.compliance=RFC7230
## HTTP Compliance: RFC7230, RFC7230_LEGACY, RFC2616, RFC2616_LEGACY, LEGACY or CUSTOMn
# jetty.http.compliance=RFC7230_LEGACY