Syncro SVN Client

svn+ssh protocol not working for me

Having trouble installing Syncro SVN Client? Got a bug to report? Post it all here.

svn+ssh protocol not working for me

Postby david » Wed May 02, 2007 1:38 am

I am unable to get the svn+ssh protocol to work when browsing a repository or using a working copy created with that protocol. Neither password nor private key authentication works; it just shows the same dialog over and over. I'm using public/private key pairs with custom commands in the authorized_keys file, as described in Chapter 6 of "Version Control with Subversion." Everything works fine with the command line and RapidSVN. Is there anything I can do to get it to work? It seems to me that Syncro SVN should just use the command line command, instead of whatever it's doing now.
david
 
Posts: 4
Joined: Thu Feb 22, 2007 12:32 am

Postby tavy » Wed May 02, 2007 12:39 pm

Hello,

Thank you for contacting us.

I could not reproduce the problem. I also followed the steps from the Chapter 6 of "Version Control with Subversion".
I created a repository on the server using
Code: Select all
svnadmin create --fs-type fsfs /home/tavy/repos

I generated the public and private key on my computer using
Code: Select all
ssh-keygen -t dsa

I copied the public key from my computer to the server in the .ssh/authorized_keys file.
I added the command
Code: Select all
command="/usr/bin/svnserve -t -r /home/tavy"
in the authorized_keys file before the public key.
I started the SyncroSVN Client on my computer and I added the repository location
Code: Select all
svn+ssh://10.0.0.24/repos
When I was asked about the authentication I specified my username, the generated private key file from my computer and the passphrase.

After that I did not encounter any problems in browsing, adding files to the repository.

Please tell us if you encountered any problems following this steps.

Best regards,
Octavian
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Postby david » Wed May 02, 2007 11:57 pm

I tried that, but now I have a different problem. Instead of showing the authentication dialog, now an error dialog pops up: "Browsing Error: svn: No repository found in 'svn+ssh://path/to/repos'." This is for any repository I try to browse, even the ones that previously popped up the authentication dialog. Does my Subversion config file need a special setting? I have the ssh= line configured to call my ssh client with the correct username. BTW, I am using Windows, and the repository is on a Linux machine.
david
 
Posts: 4
Joined: Thu Feb 22, 2007 12:32 am

Postby tavy » Thu May 03, 2007 9:41 am

Hello,

I don't understand where is the problem in your configuration, but I suggest you a simple way to connect to the repository using the 'svn+ssh' protocol without adding a 'command' in 'authorized_keys' or modifying the 'ssh line' from 'config' file. I have no problem connecting to a repository if I use the full path in the connection string. By example I use the connection string (URL): svn+ssh://hostName/home/svn/testRepos, my repository is located in '/home/svn/testRepos' directory on the host machine.

Before you try this you have to remove from 'authorized_keys' file the "command" string, leave it in the next form:
TYPE KEY COMMENT
ssh-dsa AAAABtce9euch… user@example.com,
see 'Chapter 6. Server Configuration' from the Subversion book.

Also leave unchanged the 'config' file from client side Subversion configuration directory, I mean don't change the 'ssh= line' (comment that line).

To make sure there is no wrong authentication data saved(cached) by Subversion delete the 'auth' directory from Subversion configuration directory(client side). On Windows usually is located on {user_home}/Application Data/Subversion.

And regarding your post:
I tried that, but now I have a different problem. Instead of showing the authentication dialog, now an error dialog pops up: "Browsing Error: svn: No repository found in 'svn+ssh://path/to/repos'."

In case when you use change the 'authorized_keys' by adding command:
Code: Select all
command="/path/to/svnserve -t -r /virtual/root
you have to use a relative path to repository in connection string. By example if your repository is located on 'home/svn/testRepos' and you use the command
Code: Select all
command="/path/to/svnserve -t -r /home/svn/"
you must use the connection string: svn+ssh://repostoryHostName/testRepos.

I hope this will help you.
If the problems persists please contact us to our support email address "support at syncrosvnclient dot com" and give us more details about your configuration.

Best regards,
Octavian
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Postby david » Thu May 03, 2007 6:37 pm

Thank you for the replies Octavian. I understand what you are saying, but the configuration you suggest does not suit my needs. Several people are using this repository, and I run into problems with file permissions if I don't use my current setup: all users SSH as a special user which owns the repository, and the command in the authorized_keys file includes the flag "--tunnel-user username", which sets the correct user name for each user. I'm giving up on solving this problem for now, since we have other ways of using the svn+ssh protocol.
david
 
Posts: 4
Joined: Thu Feb 22, 2007 12:32 am

Re: svn+ssh protocol not working for me

Postby Sohail » Wed Feb 27, 2008 9:43 pm

This also doesn't work for me. I'm in a corporate environment (huge global company) and we use a tunnel command like so:

/cm/tools/bin/ssh -l sahmed07 -i /Users/sohailahmed07/.ssh/id_rsa

This ties into some Kerberos authentication, different username, etc. In any event, the Syncro SVN client *needs* to support invoking a command for repository authentication to use a public key system.

Command line SVN works. Heck, the *free* SVN capabilities of Netbeans IDE 6.x give me exactly what I need. Their authentication panel has a "Use External Tunnel" entry field.

I bought version 2.x thinking I'd eventually set it up and it would be slick. But it never worked for me b/c of this issue. I finally decided to try 3.1 (I'd have to pay an upgrade too), but it still doesn't have this crucial capability that FREE IDEs bundle.

And I'm not in a small shop. I'm at a client site with a 10,000+ global employee footprint. Worth implementing this option, IMHO.

Please, Please, Please fix this!!!
Sohail
 
Posts: 3
Joined: Wed Feb 27, 2008 9:35 pm

Re: svn+ssh protocol not working for me

Postby tavy » Thu Feb 28, 2008 2:54 pm

Hello,

Thank you for contacting us.
I added an issue on our internal issue tracker regarding the ssh authentication using an external tunnel. We will consider implementing this in a future version and we will contact you when this will be available.

I do not understand if you tried to connect to your svn+ssh repository from Syncro SVN Client using the ssh public key authentication method. You can do this by specifying in the svn+ssh authentication dialog the username (in your case sahmed07), the location of the private key file (/Users/sohailahmed07/.ssh/id_rsa) and the passphrase. After this authentication succeed a second dialog will be displayed where you can specify the username you want to use for the modification made on svn. If the command in the authorized_keys file from your server includes the flag "--tunnel-user username" then in the second authentication dialog you must enter this username.
If you already tried to authenticate on that repository and you want to enter the authentication data again you can reset your current authentication data using Options->Reset Authentication action. After this you must restart Syncro SVN Client and then try again to authenticate.

If you still cannot connect to your repository please contact us to our support email address "support at syncrosvnclient dot com" and give us more details about your configuration.

Best Regards,
Octavian Nadolu
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Re: svn+ssh protocol not working for me

Postby tavy » Mon Mar 03, 2008 5:57 pm

Hello,

We added the external SSH client support for secure connections to svn+ssh repositories. This feature is available in the latest build on our download page.
To use an external SSH client you must check "Use external SSH client" from Options->Preferences->SVN page and enter the command to be executed to create the tunnel (like [path-to-ssh-client] -l user -i [path-to-private-key]).

Regards,
Octavian Nadolu
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Re: svn+ssh protocol not working for me

Postby Sohail » Mon Mar 03, 2008 9:30 pm

Octavian,

I appreciate you guys putting this updated build in. Without the tunnel command, PK authentication wasn't working. It would just redisplay the auth dialog, not explaining what was wrong.

With the latest build however, I still can't get through. My local computer username is different than my kerberos/ssh username and normally, this is handled by the tunnel command I use:

/cm/tools/bin/ssh -l sahmed07 -i /Users/sohailahmed07/.ssh/id_rsa

But, in the case of the new build, I'm just getting the error dialog:

"Browsing error: svn: Authentication error from server: Requested username does not match".

I am kerberos auth'd, as I can do an svn update in a Terminal window on my Mac and NetBeans is happy with SVN too.

The "console" tab doesn't display any more info about what's going on. All it says is:

- svn status --verbose daedalus
- operation successful

I get the error dialog whenever I try to expand the repository view.

Any ideas?
Sohail
 
Posts: 3
Joined: Wed Feb 27, 2008 9:35 pm

Re: svn+ssh protocol not working for me

Postby tavy » Tue Mar 04, 2008 1:03 pm

Hello,

First you will probably need to reset your authentication information (From the menu: 'Options' -> 'Reset Authentication') and then restart the application.

Next time you start the application and try to browse the svn+ssh repository, you should be asked about a username(The username used for connecting to the SVN repository). The default displayed user name will be the one you are using on your current machine(I'm guessing: sohailahmed07). However, as you have previously specified the username for the ssh client is different. In your case, I think that the SVN username is the same as the SSH username so that is the one you need to enter(I'm guessing: sahmed07).
Please let me know how this works for you.

There are cases when the SVN username is different than the SSH username because several users are connecting with the same SSH username with individual private keys. In these cases each user will have a SVN username to differentiate each other.

Regards,
Octavian
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Re: svn+ssh protocol not working for me

Postby tavy » Tue Mar 04, 2008 5:49 pm

Hello again,

Please note that we have another build(2008030417) on the download page that includes an option which will let you use a default or custom SVN user when using an external SSH client. You can find it in Options -> Preferences -> SVN option page.

If the 'Default SVN user' option is chosen you will no longer be asked to provide a user name, the default SVN user provided by the SSH connection will be used.

If the 'Prompt for SVN user' option is chosen, you will be asked for a SVN user like in the previous build, but you can still use the default SVN user if you leave the field empty.

If this still does not work please contact us on our support email address support@syncrosvnclient.com

Regards,
Octavian Nadolu
tavy
 
Posts: 52
Joined: Wed Jan 31, 2007 2:53 pm

Re: svn+ssh protocol not working for me

Postby Sohail » Tue Mar 04, 2008 6:01 pm

This latest build works for me. I had to choose the "default user" approach. The "prompt user" approach didn't work for me. It errors out without actually prompting, but just reporting that the user didn't match.

Regardless, I now have a solution. Thanks much!
Sohail
 
Posts: 3
Joined: Wed Feb 27, 2008 9:35 pm


Return to Common Problems

Who is online

Users browsing this forum: No registered users and 2 guests


© 2002-2013 SyncRO Soft Ltd. All rights reserved. | Sitemap | Terms of Use | Privacy Policy | This website was created & generated with <oXygen/>® XML Editor