sshnet / sshnet/SSH.NET

SftpClient connect exception ""no existing connection"

Open
#276 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
4.4k
Forks
993
Avg merge
9d 21h
Merged PRs (30d)
1

Description

I did a small program that does a SftpClient connect call.
When I run the program on
a Windows 10 PC that I have administrator permissions, all works built with Visual Studio 2015

When I run the program on a Windows 7 PC (Visual Studio 2013) that I do not have administrator permissions,
I get an exception after the "connect" call

"no existing connection. Will make new connection to server 127.0.0.1
Exception has been thrown by the target of an invocation"

I am using

SftpClient sftp = new SftpClient("127.0.0.1", username, password);
sftp.Connect();

the differences between the 2 cases seems to be only

  1. administrator permissions
  2. Windows 10 versus 7
  3. Visual Studio 2015 versus 2013

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source files or tests are named. Start by reproducing the supplied SftpClient snippet under the reported Windows 7, non-administrator, and Visual Studio 2013 conditions, then compare the full exception details with the working environment. Done means identifying the environment-specific cause and providing a verified fix or compatibility guidance.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
networking, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.