User2012384
User2012384

Reputation: 4919

set Sharpssh sftp connection timeout

I am using sharpssh.dll and want to connect to a sftp server, but if the sftp server is diconnected from network, the program will wait for a long time before "timeout" message is shown, is there anyway to set a timeout sharpssh?

Upvotes: 2

Views: 2471

Answers (1)

MattGWagner
MattGWagner

Reputation: 1156

As of right now, I don't think SharpSSH's API exposes the timeout functionality of the Session in Sftp.cs. It's available in some of the lower level implementation classes, so I don't know how difficult it would be to do right now.

I've been rolling in some patches to SharpSSH, though I don't do much work on it anymore so I wouldn't really deem it "supported". You can submit a request at https://bitbucket.org/mattgwagner/sharpssh if you'd like.

Though, you may want to check out http://sshnet.codeplex.com/ which is a much cleaner, supported library for your SSH needs.

Upvotes: 1

Related Questions