JIRA issue collector https

We have changed our JIRA server to run behind a nginx that strips https, and send the request to JIRA via http. And we also changed the JIRA base URL to https://.

An error occurs when calling the issue collector:

Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('http://jira.ourserver.com') does not match the recipient window's origin ('https://jira.ourserver.com').

When the baseURL is changed to https:// i would suppose that it would be changed in the javascript requested by the jQuery.ajax call.

How can we fix this issue?

 

5 answers

1 accepted

This widget could not be displayed.

Hi @Kasper Bakmann
specify you in server.xml options scheme/proxyName/proxyPort?

Exactly, in 

<Connector

of your server.xml (Apache tomcat under config dir)

Add

proxyName="jira.ourserver.com"  proxyPort="443" scheme="https" secure="true" 

@Viktor Okolot [Polontech] @Sash [ConfiForms] I have updated the description of the problem. We do not use a certificate on our JIRA server. Sorry for misinforming you .. And thanks for the kind replies.

This widget could not be displayed.
Steven Behnke Community Champion Feb 03, 2016

I am not certain of the strategy to accomplish this. Did you check the javascript file you're downloading inline? The script references HTTP and HTTPS and it looks like this – 

&lt;script type="text/javascript" src="https://jira.domain.com/s/79b3b8767086874764c0e633d4d3f1c2-T/en_USxto4uu/64019/67/1.4.25/_/download/batch/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector.js?locale=en-US&amp;collectorId=3a44c071"&gt;&lt;/script&gt;

 

Perhaps you just need to delete and recreate the issue-collector?

This widget could not be displayed.

Hi @Steven Behnke 

Thanks for your quick reply.

We call the script via jQuery.ajax and the url looks like this:

https://jira.ourserver.com/s/7104f7a36d38bc662345373183b87543-T/da_DKbxlvll/6332/3/1.4.15/_/download/batch/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector-embededjs/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector-embededjs.js?locale=da-DK&collectorId=e2592a74

I can not see that should cause any problems - do you?

I have tried to recreate the issue collector and the script created by JIRA suggests using http://jira... not https:// .. hmm that seems strange, is there another base url we should set?

This widget could not be displayed.
Steven Behnke Community Champion Feb 03, 2016

I see. I read your Question more closely.

  • External traffic navigates to NGINX
  • NGINX terminates SSL and proxies JIRA

Viktor and Sash are both correct, you need to inform Tomcat that it is being proxied to an SSL connection on port 443 (https). Please do follow their directions about modifying the server.xml file.

Secondly, you could also try entering the reference to JIRA in your script so it looks like so – //jira.ourserver.com/. Notice the lack of 'http:' or 'https:'. Not sure if that will help your proxy issue though.

This widget could not be displayed.

@Viktor Okolot [Polontech] + @Sash [ConfiForms] + @Steven Behnke .. Changing the Connector with proxyPort and proxyName did the trick as you adviced me to do. Thank you guys!

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted yesterday in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

68 views 0 1
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you