fritzbrand / svn-time-lapse-view

Automatically exported from code.google.com/p/svn-time-lapse-view
0 stars 0 forks source link

authentication failure with svn and ssh #12

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Use a subversion repository on a server that is accessed via ssh  using keys
2. The svn command line tool automatically will go through ssh which will
go through key exchange and authenticate
3.

What is the expected output? What do you see instead?
Should be able to see time lapse

What version of the product are you using? On what operating system?
1.3 on Linux (have tried on Windows using putty svn combination which works
for command line)

Please provide any additional information below.

Original issue reported on code.google.com by subash.k...@gmail.com on 22 Oct 2007 at 3:35

GoogleCodeExporter commented 8 years ago
Please see output
org.tmatesoft.svn.core.SVNAuthenticationException: svn: Authentication required 
for
'subashk@svn+ssh://svnsm.ami.com'
    at
org.tmatesoft.svn.core.internal.wc.SVNErrorManager.authenticationFailed(SVNError
Manager.java:36)
    at
org.tmatesoft.svn.core.internal.wc.DefaultSVNAuthenticationManager.getFirstAuthe
ntication(DefaultSVNAuthenticationManager.java:169)
    at
org.tmatesoft.svn.core.internal.io.svn.SVNGanymedConnector.open(SVNGanymedConnec
tor.java:62)
    at org.tmatesoft.svn.core.internal.io.svn.SVNConnection.open(SVNConnection.java:60)
    at
org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.openConnection(SVNRepos
itoryImpl.java:970)
    at
org.tmatesoft.svn.core.internal.io.svn.SVNRepositoryImpl.getLatestRevision(SVNRe
positoryImpl.java:140)
    at com.jonathanaquino.svntimelapseview.SvnLoader.loadRevisionsProper(SvnLoader.java:87)
    at com.jonathanaquino.svntimelapseview.SvnLoader.access$0(SvnLoader.java:80)
    at com.jonathanaquino.svntimelapseview.SvnLoader$2.execute(SvnLoader.java:63)
    at
com.jonathanaquino.svntimelapseview.helpers.MiscHelper.handleExceptions(MiscHelp
er.java:24)
    at com.jonathanaquino.svntimelapseview.SvnLoader$1.run(SvnLoader.java:61)
    at java.lang.Thread.run(Thread.java:619)

Original comment by subash.k...@gmail.com on 22 Oct 2007 at 3:36

GoogleCodeExporter commented 8 years ago
This is a duplicate of bug #6.

Hopefully this time it will be addressed instead of being marked invalid.

Original comment by ande...@gmail.com on 22 Oct 2007 at 5:09

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I have the same problem.

Original comment by jedu...@gmail.com on 23 Oct 2007 at 8:19

GoogleCodeExporter commented 8 years ago
Hi all,

I could not get this to work on a windows/putty/pageant combo. I have read on 
the
SVNKit that it uses the ganymed ssh implementation when the protocol is svn+ssh 
and
it seems that this needs access to the OpenSSH private key.

But I got it to work with pageant by adding a new tunnel to the subversion conf 
file
(under Application Data - Subversion) called plink that points to plink =
C:\\Programs\\putty\\plink.exe. 

Then by using the subversion path svn+plink:// instead of svn+ssh:// it should 
work.
Unfortunately there is a bug in the source code of this project that does not 
allow
the svnkit to use the tunnels. So adding the following line in SvnLoader.java 
as line
155 does the trick:

repository.setTunnelProvider(SVNWCUtil.createDefaultOptions(true));

I would think that it should be the same on Linux. I do not think that the 
ganymed
implementation can access the ssh-agent (like it cannot access the pageant
application on Windows).

Cheers

Kim Tiedemann
kimtiede { at } gmail.com

Original comment by kimti...@gmail.com on 23 Oct 2007 at 3:21

GoogleCodeExporter commented 8 years ago
Implemented Kim's suggestion in Revision 29.

Kim - Is this about the best we can do for svn+ssh users? If so, I guess I'll 
close
this bug

Original comment by jonathan...@gmail.com on 24 Oct 2007 at 1:48

GoogleCodeExporter commented 8 years ago
Jonathan - I guess we could supply a way of loading an OpenSSH private key file 
and
providing a text field for the passphrase - then we could load this file when
creating a auth manager by using the method:

ISVNAuthenticationManager createDefaultAuthenticationManager(File configDir, 
String
userName, String password, File privateKey, String passphrase, boolean 
storeAuth)

Instead of the current implementation only supplying a username/password.

But perhaps someone could supply a better solution?

/Kim

Original comment by kimti...@gmail.com on 24 Oct 2007 at 6:49

GoogleCodeExporter commented 8 years ago
Thanks for the responses..do you know if the 1.5 already has revision 29 
changes in
it or should I wait for a further version to check it out? I did try 1.5 but no
effect the problem remains atleast in Linux. THanks in advance

Original comment by subash.k...@gmail.com on 24 Oct 2007 at 2:20

GoogleCodeExporter commented 8 years ago
Hi Subash - yes, 1.5 has the revision 29 change. It's not an automatic solution 
- it
requires the "plink" workaround that Kim mentioned above.

Original comment by jonathan...@gmail.com on 25 Oct 2007 at 3:02

GoogleCodeExporter commented 8 years ago
hmm..thanks but sadly that doesnt seem to do it for linux
Will experiment. FWIW maybe the backed to svn can be just to spawn and svn and 
get
stuff out instead of relying on a specific engine. When I find time I can 
contribute
it if needed. Basically, just to spawn svn and get the file operations so that 
all
svn operations would just simply depend on the command line executing properly

Original comment by subash.k...@gmail.com on 25 Oct 2007 at 1:35

GoogleCodeExporter commented 8 years ago
It works perfectly for the ubuntu I have tried it on. Do the following:

Edit the file .subversion/config file in your home directory. Add the following 
under
the tunnels section:

ssh2 = ssh

Load your certificate file in the ssh-agent by:

eval `ssh-agent`
ssh-add

Check out the subversion repository using svn+ssh2:// instead of the 
svn+ssh://. Now
you can start the svn-time-lapse-view application in browse to the newly 
checked out
repository and select a file and see the revisions.

/Kim

Original comment by kimti...@gmail.com on 25 Oct 2007 at 2:45