Integration between Bitbucket and JIRA fails with a 404

I am trying to link a newly installed self-hosted version of JIRA 5.2.6 with a Bitbucket account. I have created my OAuth credentials in Bitbucket but when I try and link the accounts through JIRA I get the following error:

Not Found (404)

/api/1.0/oauth/authenticate

Could not find what you were looking for. Maybe you should raise an issue.

This error is reported from my Jira instance and the reported URL is http://jiraserver/api/1.0/oauth/authenticate?oauth_token=[removed]

Where jiraserver is a publicly accessible server name.

If I can provide any additional data then let me know, if anyone thinks that this is a genuine issue and not a case of user error then I will open an issue.

Thanks,

Anthony

8 answers

This widget could not be displayed.

This has been bothering me for over a year now. And I cannot believe how easy it was to fix (At least for Bitbucket). I did not want to remove the proxy on the IIS or mess around with that, as it took us a while to get that all working correctly. I was able to get this to work, by following the steps below:

  • Follow the standard DVCS flow until you hit the 404 error
  • Look at the URL that you have example:
    • http://{jiraserver}/api/1.0/oauth/authenticate?oauth_token={token}
  • Change the {jiraserver} to bitbucket.org

    • http://bitbucket.org/api/1.0/oauth/authenticate?oauth_token={token}
  • Press enter and continue the authentication workflow as if the 404 never happened

Thank you for posting this!

Thanks. You save my life.

This widget could not be displayed.

My solution was to shut off the reverse proxy in IIS and remove the proxy settings in the server.xml settings so the app runs on localhost and then it will redirect to the proper bitbucket page.

This widget could not be displayed.

I have now opened a support ticket for this issue, reference JSP-151786

This widget could not be displayed.

I have the exact same problem. It seems to be a tomcat proxy issue that is rewriting the bitbucket oauth outgoing link to the calling jira server (I think).

Is there some progress on the issue? I cannot get the link to the ticket referred by Anthony...

This widget could not be displayed.

Same here. I have JIRA running on proxied SSL. I open an issue, click on the Source tab at the bottom, then select Bitbucket and click the Configure button. This is rewarded with a 404 on the url:

https://example.com/p/jira/secure/admin/ConfigureBitbucketOAuth!default.jspa

The path /p/jira is configured by myself.

However the DVCS connection works fine. I can view commits on JIRA and JIRA issues on Bitbucket.

By the way, @Anthony Williams, I didn't find your issue JSP-151786.

This widget could not be displayed.

Add another to the pile. Was this ever sorted out?

404 when attempting to access https://{myaccount}.atlassian.net/secure/admin/ConfigureBitbucketOAuth!default.jspa

This widget could not be displayed.

ok, typo... found it. Why not fix it in the ondemand version? Shouldn't be hard....

This widget could not be displayed.

My solution was to shut off the reverse proxy in IIS and remove the proxy settings in the server.xml settings so the app runs on localhost and then it will redirect to the proper bitbucket page.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Aug 22, 2018 in Marketplace Apps

How a Marketplace app tech team is achieving gender diversity

Hello! My name is Genevieve Blanch, and I'm the Marketing Manager at RefinedWiki, creators of apps to give teams the tools to customize Atlassian platforms. Currently, 44% of the tech team at Re...

491 views 3 18
Read article

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