Inedo Community Forums Forums
    • Recent
    • Tags
    • Popular
    • Login

    Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

    If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

    Bitbucket authentication issues

    Scheduled Pinned Locked Moved Support
    4 Posts 2 Posters 10 Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • B Offline
      brandon_owensby_2976
      last edited by

      I'm trying to set up a demo of your software to show to my company. I've used your software for years but in the past I've used GitHub. Now I'm trying to use a Bitbucket Server and it is getting a 401 when trying to access the repository.

      Before I go any further I'm using 2025.5 (Build 14).

      When I first set it up I used the standard bitbucket path. The dropdowns worked beautifully to pick the repository in question but when it tried to clone it got a 401 error. After browsing your forums I tried setting up a generic git repository and I get the same result when it tries to clone. I'm hoping someone can either provide more information (like are are there version limitations on support) or give me some idea of how I can troubleshoot further. I'd hate for the company to miss out on this great product for something like this.

      stevedennisS 1 Reply Last reply Reply Quote 0
      • stevedennisS Offline
        stevedennis inedo-engineer @brandon_owensby_2976
        last edited by

        Hi @brandon_owensby_2976 ,

        Thanks for the feedback. Based on what you described, it sounds like...

        • BitBucket Server API is working fine
        • Git API is not working due to a failed/failing authentication challenge

        You were able to confirm this with the "Generic Git Repository" also not working. If you were to do a curl -I -u USERNAME;APIKEY https:/.../.git you would most certainly get a 401 response as well.

        Anyway that's where I would start -- try to figure out why the Git API is not accepting the credentials. It's most likely related to permissions on theh key, but it's really hard to say... just a guess.

        Thankks,
        Steve

        B 1 Reply Last reply Reply Quote 0
        • B Offline
          brandon_owensby_2976 @stevedennis
          last edited by

          Hi @stevedennis ,
          Thank you for the response. I tried the curl you mentioned and it actually prompts me for a host password for user. Of course entering this in doesn't help. I even had an admin check and see if HTTP(s) SCM hosting is enabled on our server, and it is. We do have an older version of Bitbucket Server and here soon we are supposed to be migrating to a new one. If I don't figure this out before then I will be curious if the new server makes a difference. I haven't see anything about what versions you do or don't support.

          Thank you,
          Brandon

          stevedennisS 1 Reply Last reply Reply Quote 0
          • stevedennisS Offline
            stevedennis inedo-engineer @brandon_owensby_2976
            last edited by

            Hi @brandon_owensby_2976 ,

            It sounds like you're on the right rack with troubleshooting; the issue is definitely on the server-side in this case, so I asked ChatGPT. Who knows if any of this is accurate, but...

            This is a very common situation with older versions of Bitbucket Server (especially pre-6.x / pre-7.x era, but even up to some 7.x versions in certain setups).

            The REST API (e.g. /rest/api/1.0/...) and the Git Smart HTTP protocol (/scm/.../info/refs, /git-upload-pack, etc.) are handled by different authentication filters in Bitbucket Server.

            Most likely you're using a Personal Access Token / HTTP Access Token (most frequent cause in older versions). In many Bitbucket Server versions (especially ≤ 7.17–7.21), HTTP access tokens were designed mainly for REST API and did not work reliably (or at all) for Git over HTTPS in many cases.

            As a workaround , you need to use a real username + password (or username + app password if 2FA is on) for Git operations

            We've seen similar in really old version of ADO, GitHub, etc, where API tokens wouldn't work for Git.

            Anyway, I would try that - at least from the curl side of things. And maybe upgrading will help as well. If it works, then you'll likely only be able to use a Generic Git repository with a real username/password -- and just create a special builds user which effectiveely acts like an APi key.

            Cheers,
            Steve

            1 Reply Last reply Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • 1 / 1
            • First post
              Last post
            Inedo Website Home • Support Home • Code of Conduct • Forums Guide • Documentation