Bug 40940 - java.lang.ArrayIndexOutOfBoundsException during sendHeader
Summary: java.lang.ArrayIndexOutOfBoundsException during sendHeader
Status: RESOLVED INVALID
Alias: None
Product: Tomcat 5
Classification: Unclassified
Component: Connector:Coyote (show other bugs)
Version: 5.5.20
Hardware: Other other
: P4 major (vote)
Target Milestone: ---
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-11-09 16:24 UTC by Jarkko Lietolahti
Modified: 2007-04-05 07:51 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jarkko Lietolahti 2006-11-09 16:24:39 UTC
02:11:31,035 ERROR [STDERR] java.lang.ArrayIndexOutOfBoundsException: 8192
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.http11.InternalOutputBuffer.write(InternalOutputBuffer.java:720)
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.http11.InternalOutputBuffer.write(InternalOutputBuffer.java:627)
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.http11.InternalOutputBuffer.sendHeader(InternalOutputBuffer.java:500)
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.http11.Http11Processor.prepareResponse(Http11Processor.java:1615)
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.http11.Http11Processor.action(Http11Processor.java:962)
02:11:31,035 ERROR [STDERR] 	at org.apache.coyote.Response.action(Response.java:182)
02:11:31,035 ERROR [STDERR] 	at
org.apache.coyote.Response.sendHeaders(Response.java:378)
02:11:31,035 ERROR [STDERR] 	at
org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:317)
02:11:31,035 ERROR [STDERR] 	at
org.apache.catalina.connector.OutputBuffer.close(OutputBuffer.java:278)
02:11:31,035 ERROR [STDERR] 	at
org.apache.catalina.connector.Response.finishResponse(Response.java:476)
02:11:31,036 ERROR [STDERR] 	at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
02:11:31,036 ERROR [STDERR] 	at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
02:11:31,036 ERROR [STDERR] 	at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
02:11:31,036 ERROR [STDERR] 	at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
02:11:31,036 ERROR [STDERR] 	at
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
02:11:31,036 ERROR [STDERR] 	at java.lang.Thread.run(Thread.java:619)
02:11:32,011 ERROR [Http11Processor] Error finishing response
java.lang.ArrayIndexOutOfBoundsException
	at java.lang.System.arraycopy(Native Method)
	at
org.apache.coyote.http11.InternalOutputBuffer.write(InternalOutputBuffer.java:689)
	at
org.apache.coyote.http11.InternalOutputBuffer.sendStatus(InternalOutputBuffer.java:428)
	at
org.apache.coyote.http11.Http11Processor.prepareResponse(Http11Processor.java:1604)
	at org.apache.coyote.http11.Http11Processor.action(Http11Processor.java:962)
	at org.apache.coyote.Response.action(Response.java:180)
	at
org.apache.coyote.http11.InternalOutputBuffer.endRequest(InternalOutputBuffer.java:388)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:906)
	at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
	at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
	at java.lang.Thread.run(Thread.java:619)



org.apache.coyote.http11.InternalOutputBuffer.i=7944
org.apache.coyote.http11.InternalOutputBuffer.len = 15157
org.apache.coyote.http11.InternalOutputBuffer.c = 3


=== MimeHeaders ===
X-Powered-By = Servlet 2.4; JBoss-4.0.5.GA (build: CVSTag=Branch_4_0
date=200610162339)/Tomcat-5.5
Set-Cookie = COOKIE_SUPPORT=true; Expires=Sat, 10-Nov-2007 00:18:39 GMT; Path=/
Location = ... has jsf_state_64 variable with very long contents
(=amJzMXszAAAAATMAAAACAAATW0....)
Comment 1 Remy Maucherat 2006-11-09 17:03:23 UTC
This behavior is not dynamic, so you have to adjust the maxHeaderSize according
to your needs.
Comment 2 Bob Herrmann 2007-04-05 07:51:30 UTC
Hi, What about at least changing the exception to be something slight more
helpful , like a header has execeded the 4k (or MAXHEADER) limit - please reduce
the size of the header or increase Tomcat's max header.  See wiki page....