https://issues.apache.org/bugzilla/show_bug.cgi?id=47426

           Summary: 400 Bad Request when sending two consecutive POST
                    requests over the same connection
           Product: Tomcat 5
           Version: Unknown
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Connector:Coyote
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: bart.vanha...@punchtelematix.com


I have a web service deployed on tomcat-5.5.15 (bundled in jboss-4.2.3). The
web-service is reacheable from an apache 2.2.11 web server, through mod_jk
1.2.29. Everything is deployed on openSuSE 11.0 (but with updated apache en
mod_jk packages). 

In the following scenario, I get a strange 400 Bad Request error report back:
On the same connection, sent two POST requests (HTTP/1.1 with connection
keep-alive). The value of the content length of the first request is between
512 and 768 bytes. The size of the second POST request does not matter.

In the server logs, I see:

java.lang.ArrayIndexOutOfBoundsException: 15432
    at org.apache.coyote.ajp.AjpMessage.getInt(AjpMessage.java:301)
    at org.apache.coyote.ajp.AjpMessage.getBytes(AjpMessage.java:327)
    at org.apache.coyote.ajp.AjpProcessor.prepareRequest(AjpProcessor.java:641)
    at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:425)
    at
org.apache.coyote.ajp.AjpProtocol$AjpConnectionHandler.process(AjpProtocol.java:366)
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
    at java.lang.Thread.run(Thread.java:595)


The strange thing is, if the size is smaller than 512 or bigger than 768, I get
no Bad Request result. If I do the requests directly to tomcat, there is also
no problem. 

I am not sure the problem is in tomcat or in mod_jk, I just picked the most
plausible one. The trace logging of mod_jk does not show any problems: the
second request is printed correctly.

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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

Reply via email to