Unable to Attach File into JIRA via HTTPS

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

  • User can attach file into JIRA when HTTP connection is used. However, the same file can't be attached when JIRA is accessed via HTTPS. 
  • JIRA is integrated with Mod JK proxy

The following appears in the atlassian-jira.log:

/rest/internal/1.0/AttachTemporaryFile [common.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service
java.lang.IllegalArgumentException: Header message of length [8,194] received but the packetSize is only [8,192]
	at org.apache.coyote.ajp.AjpProcessor.readMessage(AjpProcessor.java:380)
	at org.apache.coyote.ajp.AjpProcessor.receive(AjpProcessor.java:331)
...


Diagnosis

Check if the JIRA's server.xml has AJP connector enabled:

  <Connector port="8009" redirectPort="8443" enableLookups="false" protocol="AJP/1.3" URIEncoding="UTF-8"/>

 

Cause

AJP connector does not have maxHttpHeaderSize but the equivalent parameter accepted is packetSize which by default set to 8192.  However, there seems to be known problem with packetSize and SSL with AJP connector. To quote Apache Tomcat AJP's documentation :

Problems with the default value have been reported when sending certificates or certificate chains.

Workaround

  • increase the packetSize in JIRA's server.xml and max_packet_size in the Mod JK configuration OR
  • investigate on the certificate and the certificate chains in the Mod JK side and fix it in the proxy side
Last modified on Mar 30, 2016

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.