0 votes
by (140 points)

I am using sftp and able to connect and browse list of files but download of files is breaking.This is keyboard interactive authentication .I tried both download and getfile methods and always getting error that "server has closed the connection".

I am able to download as many files from WINSCP so its not server side issue.

below is debug log :

SSH: Error occured while receiving SSH packet: Rebex.Net.SshException: The connection was closed by the server. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
at Rebex.Net.ProxySocket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
at Rebex.Net.SshSession.MM(Int32 C, Int32 V)
--- End of inner exception stack trace ---
at Rebex.Net.SshSession.MM(Int32 C, Int32 V)
at Rebex.Net.SshSession.XGV(Byte[]& C)
at Rebex.Net.SshSession.CNV()
at Rebex.Net.SshSession.WM()
2019-05-20 08:01:55.518 ERROR Sftp(1)[1] SSH: Rebex.Net.SshException: The connection was closed by the server. ---> Rebex.Net.SshException: The connection was closed by the server. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
at Rebex.Net.ProxySocket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
at Rebex.Net.SshSession.MM(Int32 C, Int32 V)
--- End of inner exception stack trace ---
at Rebex.Net.SshSession.MM(Int32 C, Int32 V)
at Rebex.Net.SshSession.XGV(Byte[]& C)
at Rebex.Net.SshSession.CNV()
at Rebex.Net.SshSession.WM()
--- End of inner exception stack trace ---
at Rebex.Net.SshSession.LGV()
at Rebex.Net.SshSession.DGV[C,V](TTG2 C, Int32 V, ITG Z, V N, C Q, C M) at Rebex.Net.SshSession.DGV[C,V](TTG2 C, V V)
at Rebex.Net.SshChannel.PZ[C,V](TTG`2 C, V V)
at Rebex.Net.SshChannel.Receive(Byte[] buffer, Int32 offset, Int32 count)
2019-05-20 08:01:55.518 DEBUG Sftp(1)[1] Info: Waiting for 15 outstanding read requests to arrive.
2019-05-20 08:01:55.518 ERROR Sftp(1)[1] Info: Rebex.Net.SftpException: The server has closed the connection.
at Rebex.Net.TOG.FZ(Int32 C)
at Rebex.Net.TOG.BZ(NW& C)
at Rebex.Net.TOG.BZ(UInt32 C, Boolean V)
at Rebex.Net.TOG.HV(UInt32 C, TUG V)
at Rebex.Net.Sftp.LEV(TUG C, String V, Stream Z, Int64 N, Int64 Q, IQ M)

Applies to: Rebex SFTP

1 Answer

0 votes
by (70.2k points)

Can you please try to download the files using the SftpWinFormClient sample?

If you are not able to download the files using our sample, please send us log files produced by our sample and produced by WINSCP. Please send it to support@rebex.net

Please ensure that you enabled Debug log at the sample, as shown on the image.

enter image description here

by (140 points)
as I mentioned this sftp server do keyboard interactive authentication . SftpWinFormClient failed while connecting only as it does seems to be supporting
"keyboard interactive authentication . "
by (140 points)
I am expecting help here..can you please respond
by (70.2k points)
Can you please send us the log produced by the SftpWinFormClient sample?
The sample is able to handle keyboard-interactive authentication.
...