Integration between Bitbucket and JIRA fails with a 404

Anthony Williams February 7, 2013

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

6 votes
blairstewart October 7, 2015

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
Jason Plumhoff
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 17, 2015

Thank you for posting this!

van-ly April 3, 2016

Thanks. You save my life.

1 vote
enkodellc January 24, 2015

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.

0 votes
enkodellc January 24, 2015

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.

0 votes
Robert Hof February 17, 2014

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

0 votes
Robert Hof February 17, 2014

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

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

0 votes
daniel.ly October 16, 2013

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.

0 votes
Carl St-Laurent March 14, 2013

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...

0 votes
Anthony Williams February 12, 2013

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

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events