Author: kkolinko
Date: Fri Jan  6 15:55:12 2012
New Revision: 1228240

URL: http://svn.apache.org/viewvc?rev=1228240&view=rev
Log:
Do not throw IllegalArgumentException from parseParameters() call when
chunked POST request is too large, but treat it like an IO error.

Modified:
    tomcat/tc6.0.x/trunk/STATUS.txt
    tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/Request.java
    tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml

Modified: tomcat/tc6.0.x/trunk/STATUS.txt
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=1228240&r1=1228239&r2=1228240&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/STATUS.txt (original)
+++ tomcat/tc6.0.x/trunk/STATUS.txt Fri Jan  6 15:55:12 2012
@@ -80,13 +80,6 @@ PATCHES PROPOSED TO BACKPORT:
   +1: kkolinko,funkman
   -1:
 
-* Do not throw IllegalArgumentException from parseParameters() call when
-  chunked POST request is too large, but treat it like an IO error.
-  http://svn.apache.org/viewvc?rev=1206200&view=rev
-  (without tests; it is r1206205 in TC7)
-  +1: kkolinko,funkman, rjung
-  -1:
-
 * Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=52293
   Correctly handle antiResourceLocking=true when unpackWARs=false
   Correctly handle multi-level contexts when antiResourceLocking=true

Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/Request.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/Request.java?rev=1228240&r1=1228239&r2=1228240&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/Request.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/Request.java Fri 
Jan  6 15:55:12 2012
@@ -2651,7 +2651,7 @@ public class Request
                 try {
                     formData = readChunkedPostBody();
                 } catch (IOException e) {
-                    // Client disconnect
+                    // Client disconnect or chunkedPostTooLarge error
                     if (context.getLogger().isDebugEnabled()) {
                         context.getLogger().debug(
                                 sm.getString("coyoteRequest.parseParameters"), 
e);
@@ -2705,7 +2705,7 @@ public class Request
             if (connector.getMaxPostSize() > 0 &&
                     (body.getLength() + len) > connector.getMaxPostSize()) {
                 // Too much data
-                throw new IllegalArgumentException(
+                throw new IOException(
                         sm.getString("coyoteRequest.chunkedPostTooLarge"));
             }
             if (len > 0) {

Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml?rev=1228240&r1=1228239&r2=1228240&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Fri Jan  6 15:55:12 2012
@@ -68,6 +68,12 @@
         <bug>52225</bug>: Fix ClassCastException when adding an alias for an
         existing host via JMX. (kkolinko)
       </fix>
+      <fix>
+        Do not throw IllegalArgumentException from parseParameters() call
+        when chunked POST request is too large, but treat it like an IO error.
+        The <code>FailedRequestFilter</code> filter can be used to detect this
+        condition. (kkolinko)
+      </fix>
     </changelog>
   </subsection>
   <subsection name="Jasper">



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to