Description
var connectionInfo = new ConnectionInfo("a.host.name", 22, username, ProxyTypes.Socks5, "127.0.0.1", 9050, "", "", new PasswordAuthenticationMethod(username, password) );
Results in the following exception. I can use the specified proxy in putty, firefox, other applications etc just fine, however it is not working with SSH.NET
Unhandled Exception: Renci.SshNet.Common.SshConnectionException: An established connection was aborted by the server.
at Renci.SshNet.Abstractions.SocketAbstraction.Send(Socket socket, Byte[] data, Int32 offset, Int32 size)
at Renci.SshNet.Session.ConnectSocks5()
at Renci.SshNet.Session.Connect()
at Renci.SshNet.BaseClient.Connect()
at WS.Program.Main(String[] args)
If I try to use localhost instead of 127.0.0.1, the following different exception is thrown
Unhandled Exception: System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it
at Renci.SshNet.Abstractions.SocketAbstraction.Connect(IPEndPoint remoteEndpoint, TimeSpan connectTimeout)
at Renci.SshNet.Session.SocketConnect(String host, Int32 port)
at Renci.SshNet.Session.Connect()
at Renci.SshNet.BaseClient.Connect()
at WS.Program.Main(String[] args)