Connection refused when using localhost ssh tunnel

Advertisement

rene
Guest

Connection refused when using localhost ssh tunnel

I have simple ssh tunnel on localhost. When I try to connect to my ssh server via this tunnel, winscp (.com | .exe) ends with "Connection refused". Direct connection works well, older version of WinSCP (4.0.3.345) works too.
I am running on Windows 7 SP1.

Direct connection to ssh server [works]:
c:\winscp.com
winscp> open user1:pass1word@myserver1
Searching for host...
Connecting to host...
Authenticating...
Using username "mihula".
Authenticating with pre-entered password.
Authenticated.
Starting the session...
Reading remote directory...
Session started.
Active session: [1] user1@myserver1
winscp>    

Connection via tunnel (myserver1 is redirected from port 60017) [fail]:
c:\winscp.com
Direct connection to ssh server [works]:
winscp> open localhost:60017
Searching for host...
Network error: Connection refused.
winscp>    

Connection via tunnel using WinSCP 4.0.3 [works]:
winscp> open user1:pass1word@localhost:60017
Searching for host...
Connecting to host...
Authenticating...
Using username "user1".
Authenticating with pre-entered password.
Authenticated.
Starting the session...
Reading remote directory...
Session started.
Active session: [1] user1@localhost    

Any ideas what I'm doing wrong?

Reply with quote

rene
Guest

Re: Connection refused when using localhost ssh tunnel

Well now I think the problem is in conflict IPv4 vs. IPv6.
If I use "127.0.0.1" instead of "localhost", winscp is connected properly.

Is there some commandline option (winscp.com script option) for addressfamily settings?

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
27,227
Location:
Prague, Czechia

Re: Connection refused when using localhost ssh tunnel

Can you send me an email, so I can send you back a debug version of WinSCP to track the problem? Please include link back to this topic in your email. Also note in this topic that you have sent the email. Thanks.

You will find my address (if you log in) in my forum profile.
_________________
Martin Prikryl

Reply with quote

Advertisement

You can post new topics in this forum