Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Clone fails always from sourcetree 3.4.3 on windows from Gitlab EE at site with error 403


I have Windows 10 Enterprise, I'm on a VPN (shouldn't matter).

I installed sourcetree portable version 3.4.3 64bit on it.

I have my ssh keys as generated by the ssh-keygen that comes with Windows 10 Enterprise. I simply ran "ssh-keygen -t ecdsa -C "my comment""

I have the public key from that pasted into my SSH public value in my gitlab account.

git operations with command line git work fine (using PortableGit 2.30.1) with these same keys (located as usual in \Users\<username>\.ssh )

I do have sourcetree set in the General tab to use openssh

When I try to a clone from the Remotes in sourcetree I always get this kind of error

Command: git -c diff.mnemonicprefix=false -c core.quotepath=false --no-optional-locks ls-remote https://<site url to gitlab>/project/subproject.git
Error: remote: Git access over HTTP is not allowed
fatal: unable to access 'https://<site url to gitlab>/project/subproject.git/': The requested URL returned error: 403

where I've made the exact URL anonymous just for posting.    What's so odd is that I cloned from the exact same gitlab with the portablegit via command line, then I imported that directory tree into sourcetree as a "local repo" and sourcetree then seems to successfully do pulls and fetches (It says "pull successful") but if I try to use sourcetree directly to clone I get the 403 type error above.  I would have thought that a fetch or pull would exercise the authentication with gitlab in much the same way as a clone.

I am using my ssh key with a passphrase and I typed that into the sourcetree agent prompt that shows when it starts up (BTW that's kind of error prone, sourcetree at startup seems to spawn a command line window to load the agent which sometimes isn't visible (might be under windows) so the user can go off and try to use sourcetree with the agent not loaded with the Passphrase. I'd suggest some kind of popup built into sourcetree so the prompt is more in your face)

1 answer

1 accepted

I found the answer myself, the clone syntax was wrong I had:

https://<host serving gitlab>/project/subproject.git

that results in the 403 so I tried:


ssh://git@<host serving gitlab>/project/subproject.git


and that worked.   I figured that out by looking in a working command line git  .git/config file and stealing the URL format from that.  So I think that means the PAT is not being used, at least not for cloning.  Maybe sourcetree uses the PAT still for getting lists of repos from the server and other stuff in the gui.  It would be helpful to show some sample url formats in the clone popup.

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events