Changes with Apache 2.4.15
+ *) core: Allow spaces after chunk-size for compatibility with implementations
+ using a pre-filled buffer. [Yann Ylavic, Jeff Trawick]
+
*) mod_ssl: Remove deprecated SSLCertificateChainFile warning.
[Yann Ylavic]
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
[ start all new proposals below, under PATCHES PROPOSED. ]
- *) core: Allow spaces after chunk-size for compatibility with implementations
- using a pre-filled buffer, and log parsing failures at level INFO.
- trunk patch: http://svn.apache.org/r1685345
- http://svn.apache.org/r1685347
- http://svn.apache.org/r1685349
- http://svn.apache.org/r1685350
- 2.4.x patch: http://people.apache.org/~ylavic/httpd-2.4.x-ap_http_filter_chunked-v3.patch
- +1: ylavic, trawick (v3), wrowe (v3)
-
*) mod_charset_lite, mod_ext_filter: Avoid inadvertent filtering of protocol
data during read of chunked request bodies. PR 58049.
trunk patch: http://svn.apache.org/r1686085
BODY_CHUNK, /* chunk expected */
BODY_CHUNK_PART, /* chunk digits */
BODY_CHUNK_EXT, /* chunk extension */
- BODY_CHUNK_LF, /* got CR, expect LF after digits/extension */
+ BODY_CHUNK_CR, /* got space(s) after digits, expect [CR]LF or ext */
+ BODY_CHUNK_LF, /* got CR after digits or ext, expect LF */
BODY_CHUNK_DATA, /* data constrained by chunked encoding */
BODY_CHUNK_END, /* chunked data terminating CRLF */
- BODY_CHUNK_END_LF, /* got CR, expect LF after data */
+ BODY_CHUNK_END_LF, /* got CR after data, expect LF */
BODY_CHUNK_TRAILER /* trailers */
} state;
unsigned int eos_sent :1;
return APR_EINVAL;
}
}
+ else if (c == ' ' || c == '\t') {
+ ctx->state = BODY_CHUNK_CR;
+ }
+ else if (ctx->state == BODY_CHUNK_CR) {
+ /*
+ * ';', CR or LF expected.
+ */
+ return APR_EINVAL;
+ }
else if (ctx->state == BODY_CHUNK_PART) {
int xvalue;