René's URL Explorer Experiment


Title: [BUG] Azure DevOps repository cloning fails due to incorrect authentication method Description · Issue #522 · sourcebot-dev/sourcebot · GitHub

Open Graph Title: [BUG] Azure DevOps repository cloning fails due to incorrect authentication method Description · Issue #522 · sourcebot-dev/sourcebot

X Title: [BUG] Azure DevOps repository cloning fails due to incorrect authentication method Description · Issue #522 · sourcebot-dev/sourcebot

Description: Describe the bug When connecting to an Azure DevOps instance, the initial API connection and repository discovery succeed, but the subsequent git clone operation fails with an Authentication failed error. This issue stems from the way re...

Open Graph Description: Describe the bug When connecting to an Azure DevOps instance, the initial API connection and repository discovery succeed, but the subsequent git clone operation fails with an Authentication failed...

X Description: Describe the bug When connecting to an Azure DevOps instance, the initial API connection and repository discovery succeed, but the subsequent git clone operation fails with an Authentication failed...

Opengraph URL: https://github.com/sourcebot-dev/sourcebot/issues/522

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[BUG] Azure DevOps repository cloning fails due to incorrect authentication method  Description","articleBody":"### Describe the bug\n\nWhen connecting to an Azure DevOps instance, the initial API connection and repository discovery succeed, but the subsequent git clone operation fails with an Authentication failed error.\n\nThis issue stems from the way repoManager constructs the clone URL for Azure DevOps repositories.\n\n**Logs**\n\n```\nThe initial sync job shows a successful API connection:\n\n[backend] | 2025-09-19T06:42:54.369Z info: [connection-manager] Connection sync job for connection azure_devops (id: 5, jobId: 17) completed\n```\n\n\n\nHowever, the cloning process initiated by repoManager fails:\n\n```\n[backend] | 2025-09-19T06:42:54.796Z error: [repo-manager] Failed to sync repository [internal-devops-host]/mpilot_perception/auto-tagging-platform ... Error: Failed to clone repository ...\n[backend] | fatal: could not read Password for 'https://xxxxx@[internal-devops-host]': No such device or address\n```\n\n\n\n\n**Root Cause Analysis**\n\nIncorrect Credential Formatting: In packages/backend/src/repoManager.ts, the getCloneCredentialsForRepo function returns only a password (the PAT) for azuredevops connections.\n\nIncorrect URL Construction: The syncGitRepository function in the same file has a fallback mechanism that incorrectly assigns the password to the username field of the clone URL when username is not provided. This results in an improperly formatted URL like https://\u003cPAT\u003e@[internal-devops-host]/....\n\nAzure DevOps Authentication Mechanism: Azure DevOps does not support authentication via a PAT embedded in the username part of a URL. It requires the PAT to be supplied as the password in a Basic Authentication scheme, typically with an arbitrary (or empty) username.\n\n\u003cimg width=\"897\" height=\"538\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/ca758c95-1002-4af7-959f-3d8e7a788c41\" /\u003e\n\nhttps://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops\u0026tabs=Windows#use-a-pat\n\nManual Verification\n\nWe have confirmed the correct authentication method via the command line.\n\nFailed Attempt (mimicking current behavior):\n\n```\ngit clone https://pat:YOUR_PAT@[internal-devops-host]/...\n# Result: fatal: Authentication failed\n```\n\n\n\n\nSuccessful Attempt (correct method):\nThis method injects the credentials directly into the HTTP header, which is the correct way to authenticate with Azure DevOps.\n\n```\nTOKEN=\"YOUR_PAT\"\nAUTH_HEADER=\"Authorization: Basic $(echo -n \":$TOKEN\" | base64)\"\ngit -c http.extraHeader=\"$AUTH_HEADER\" clone https://[internal-devops-host]/...\n# Result: Success, cloning begins.\n```\n\n\n\nSuggested Solution\n\nThe repoManager needs to be updated to handle Azure DevOps authentication correctly.\n\nModify git.ts: The cloneRepository and fetchRepository functions in packages/backend/src/git.ts should be updated to accept an optional config parameter (a string array) to pass custom configurations like http.extraHeader to the underlying simple-git call.\n\nModify repoManager.ts: In syncGitRepository, add logic to detect if the repository is from an azuredevops connection.\n\nIf it is, construct the Authorization: Basic ... header using the PAT and pass it to cloneRepository/fetchRepository via the new config parameter.\nIf it is not, retain the existing logic of embedding credentials in the URL.\nThis will ensure that Azure DevOps repositories are cloned using the correct, header-based authentication method without affecting other Git providers.\n\n### To reproduce\n\n1. Configure a new code host connection of type azuredevops.\n2. Provide the URL for your Azure DevOps server (e.g., https://[internal-devops-host]) and a valid Personal Access Token (PAT) with at least Code (Read) permissions.\n3. Configure the connection to sync a specific repository.\n4. Trigger a sync for the connection.\n5. Observe the backend logs for the repo-manager service.\n\n### Sourcebot deployment information\n\nSourcebot version (e.g. v3.0.1): 4.7.0\n\n\n### Additional information\n\n_No response_","author":{"url":"https://github.com/yurika96","@type":"Person","name":"yurika96"},"datePublished":"2025-09-19T06:59:40.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/522/sourcebot/issues/522"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:91c90d5c-faab-4482-d535-03c58f4dfb28
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idB55A:6435C:280242E:36C7CFA:6A4EF322
html-safe-nonce72360c2dbf63ca7b1692fe565a7485deb6e02d40b281a2e35e8625316938b0dc
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNTVBOjY0MzVDOjI4MDI0MkU6MzZDN0NGQTo2QTRFRjMyMiIsInZpc2l0b3JfaWQiOiIyNTExMzE1NjgwOTU2OTY5NzYyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacf016b85d80b0af05dad74d95b6ffefb520c23aece73e76dd208d59559720434f
hovercard-subject-tagissue:3433147491
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/sourcebot-dev/sourcebot/522/issue_layout
twitter:imagehttps://opengraph.githubassets.com/9ab77a83dd18339b6b1f096be1c2c96780561174992b13995896e223dea216eb/sourcebot-dev/sourcebot/issues/522
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/9ab77a83dd18339b6b1f096be1c2c96780561174992b13995896e223dea216eb/sourcebot-dev/sourcebot/issues/522
og:image:altDescribe the bug When connecting to an Azure DevOps instance, the initial API connection and repository discovery succeed, but the subsequent git clone operation fails with an Authentication failed...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameyurika96
hostnamegithub.com
expected-hostnamegithub.com
Noneb92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9
turbo-cache-controlno-preview
go-importgithub.com/sourcebot-dev/sourcebot git https://github.com/sourcebot-dev/sourcebot.git
octolytics-dimension-user_id135396723
octolytics-dimension-user_loginsourcebot-dev
octolytics-dimension-repository_id846729675
octolytics-dimension-repository_nwosourcebot-dev/sourcebot
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id846729675
octolytics-dimension-repository_network_root_nwosourcebot-dev/sourcebot
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release2b8f23afb982271f1b22258a94aede67a6b77760
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/sourcebot-dev/sourcebot/issues/522#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsourcebot-dev%2Fsourcebot%2Fissues%2F522
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsourcebot-dev%2Fsourcebot%2Fissues%2F522
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=sourcebot-dev%2Fsourcebot
Reloadhttps://github.com/sourcebot-dev/sourcebot/issues/522
Reloadhttps://github.com/sourcebot-dev/sourcebot/issues/522
Reloadhttps://github.com/sourcebot-dev/sourcebot/issues/522
Please reload this pagehttps://github.com/sourcebot-dev/sourcebot/issues/522
sourcebot-dev https://github.com/sourcebot-dev
sourcebothttps://github.com/sourcebot-dev/sourcebot
Notifications https://github.com/login?return_to=%2Fsourcebot-dev%2Fsourcebot
Fork 318 https://github.com/login?return_to=%2Fsourcebot-dev%2Fsourcebot
Star 3.6k https://github.com/login?return_to=%2Fsourcebot-dev%2Fsourcebot
Code https://github.com/sourcebot-dev/sourcebot
Issues 92 https://github.com/sourcebot-dev/sourcebot/issues
Pull requests 37 https://github.com/sourcebot-dev/sourcebot/pulls
Discussions https://github.com/sourcebot-dev/sourcebot/discussions
Actions https://github.com/sourcebot-dev/sourcebot/actions
Security and quality 0 https://github.com/sourcebot-dev/sourcebot/security
Insights https://github.com/sourcebot-dev/sourcebot/pulse
Code https://github.com/sourcebot-dev/sourcebot
Issues https://github.com/sourcebot-dev/sourcebot/issues
Pull requests https://github.com/sourcebot-dev/sourcebot/pulls
Discussions https://github.com/sourcebot-dev/sourcebot/discussions
Actions https://github.com/sourcebot-dev/sourcebot/actions
Security and quality https://github.com/sourcebot-dev/sourcebot/security
Insights https://github.com/sourcebot-dev/sourcebot/pulse
#524https://github.com/sourcebot-dev/sourcebot/pull/524
[BUG] Azure DevOps repository cloning fails due to incorrect authentication method Descriptionhttps://github.com/sourcebot-dev/sourcebot/issues/522#top
#524https://github.com/sourcebot-dev/sourcebot/pull/524
https://github.com/msukkari
bugSomething isn't workinghttps://github.com/sourcebot-dev/sourcebot/issues?q=state%3Aopen%20label%3A%22bug%22
triage neededhttps://github.com/sourcebot-dev/sourcebot/issues?q=state%3Aopen%20label%3A%22triage%20needed%22
https://github.com/yurika96
yurika96https://github.com/yurika96
on Sep 19, 2025https://github.com/sourcebot-dev/sourcebot/issues/522#issue-3433147491
https://private-user-images.githubusercontent.com/143829185/491437483-ca758c95-1002-4af7-959f-3d8e7a788c41.png?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3ODM1NTkyNDcsIm5iZiI6MTc4MzU1ODk0NywicGF0aCI6Ii8xNDM4MjkxODUvNDkxNDM3NDgzLWNhNzU4Yzk1LTEwMDItNGFmNy05NTlmLTNkOGU3YTc4OGM0MS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjYwNzA5JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI2MDcwOVQwMTAyMjdaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1jNDk1ZjA4NTk3NWJhM2MzYWVkOTFmMmY3ZTkwZWNjNjNkNjA0ZTM3N2ViYjdlNWQzYjU2ZmUwNDViMzFiNDFhJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZyZXNwb25zZS1jb250ZW50LXR5cGU9aW1hZ2UlMkZwbmcifQ.Ff0T-16WKmqTCkKf0_VkIlQ69CRuRR6tlLymYSLogzs
https://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops&tabs=Windows#use-a-pathttps://learn.microsoft.com/en-us/azure/devops/organizations/accounts/use-personal-access-tokens-to-authenticate?view=azure-devops&tabs=Windows#use-a-pat
msukkarihttps://github.com/msukkari
bugSomething isn't workinghttps://github.com/sourcebot-dev/sourcebot/issues?q=state%3Aopen%20label%3A%22bug%22
triage neededhttps://github.com/sourcebot-dev/sourcebot/issues?q=state%3Aopen%20label%3A%22triage%20needed%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.