401382 Prevent parseAvailable from parsing next chunk when previous has not been consumed. Handle no content-type in chunked request.
This commit is contained in:
parent
27cad4960b
commit
bed3ea04f8
|
@ -581,6 +581,12 @@ public class ProxyServlet implements Servlet
|
|||
String hdr = (String)enm.nextElement();
|
||||
String lhdr = hdr.toLowerCase();
|
||||
|
||||
if ("transfer-encoding".equals(lhdr))
|
||||
{
|
||||
if (request.getHeader("transfer-encoding").indexOf("chunk")>=0)
|
||||
hasContent = true;
|
||||
}
|
||||
|
||||
if (_DontProxyHeaders.contains(lhdr))
|
||||
continue;
|
||||
if (connectionHdr != null && connectionHdr.indexOf(lhdr) >= 0)
|
||||
|
|
|
@ -265,7 +265,6 @@ public class ProxyServletTest
|
|||
"PUT /proxy/test HTTP/1.1\r\n"+
|
||||
"Host: localhost:"+_connector.getLocalPort()+"\r\n"+
|
||||
"Transfer-Encoding: chunked\r\n"+
|
||||
"Content-Type: text/plain\r\n"+
|
||||
"Connection: close\r\n"+
|
||||
"\r\n"+
|
||||
"A\r\n"+
|
||||
|
|
Loading…
Reference in New Issue