Timeout properties are ignored when connecting via a proxy
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 4.4k
- Forks
- 993
- Avg merge
- 9d 21h
- Merged PRs (30d)
- 1
Description
The problem is that we have a slow sftp server which takes some time to establish connection with. It may take up to 2 minutes to establish a connection, and after that it works fine. When connecting using various ftp-clients we increased timeout property and it worked for us.
However this does not work via the code. When trying to connect via a secured proxy - it seems that both
ConnectionInfo.Timeout and SftpClient.OperationTimeout have no effect and connection is terminated due to a timeout after ~27 seconds.
This seems to be an old issue with at least one other user facing it in 2015
http://stackoverflow.com/questions/34388446/c-sharp-renci-sshnet-sftp-client-connection-behind-proxy-timeout#comment72017745_34388446
For me it the same with Renci.SSH 2014 as well as with the latest version SSH.NET.2016.0.0
Thank you in advance for your consideration of the issue
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how proxy connections handle ConnectionInfo.Timeout and SftpClient.OperationTimeout, then reproduce the reported failure with a slow SFTP server. Check why the connection ends after about 27 seconds despite the configured values. Done means the configured timeout is honored when connecting through a secured proxy.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100