Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
417 views
in .NET FTP by (170 points)

Hi

When I try to use Cipher i got below error. Issue in in ONE DEV Box i'm getting the error but in another box with same code its working. any idea what i need to do or how i can check why its working in one server.

ftpsConnection.MinSSLVersion = SSLFTPSSLVersion.TLS1; ftpsConnection.MaxSSLVersion = SSLFTPSSLVersion.TLS12;

If comment this line then its work

ftpsConnection.CipherSuites = SSLFTPCipherSuite.RSA_AES_128_SHA | SSLFTPCipherSuite.RSA_AES_256_SHA;

DEBUG [SSLFTPControlSocket] 2 Dec 2019 11:43:27.990 :  Beginning Tls1, Tls11, Tls12 handshake.
DEBUG [SecureSocket] 2 Dec 2019 11:43:27.990 :  ChangeSecurityProtocol: Tls1, Tls11, Tls12
DEBUG [CompatibilityLayer] 2 Dec 2019 11:43:27.997 :  Local min SSL version: 3.1, max SSL version: 3.3
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.052 :  Starting handshake
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.088 :  Handshake started
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.088 :  Waiting for handshake completion
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.088 :  Waiting for handshake to complete (timeout=-1ms)
DEBUG [SocketController] 2 Dec 2019 11:43:28.109 : FTPConnection.1 OnReceive closing (size == 0)
DEBUG [SocketController] 2 Dec 2019 11:43:28.113 : FTPConnection.1 CloseConnection(e=null)
DEBUG [SocketController] 2 Dec 2019 11:43:28.113 : FTPConnection.1 Shut down socket
DEBUG [SocketController] 2 Dec 2019 11:43:28.113 : FTPConnection.1 Closed socket
DEBUG [TransferBuffer] 2 Dec 2019 11:43:28.114 : FTPConnection.1 Close() called when open
ERROR [SocketController] 2 Dec 2019 11:43:28.124 : FTPConnection.1 OnReceive - caught exception - closing: Socket closed before handshake is complete (2)
DEBUG [SocketController] 2 Dec 2019 11:43:28.124 : FTPConnection.1 CloseConnection(e=Socket closed before handshake is complete (2))
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.125 : FTPConnection.1 OnHandshakeComplete(False,Socket closed before handshake is complete (2))
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.125 : FTPConnection.1 OnHandshakeComplete - waiting for lock
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.125 : FTPConnection.1 OnHandshakeComplete - in lock
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.125 : FTPConnection.1 OnHandshakeComplete - exiting lock
DEBUG [SecureSocket] 2 Dec 2019 11:43:28.125 : FTPConnection.1 OnHandshakeComplete - exit
ERROR [SecureSocket] 2 Dec 2019 11:43:28.126 :  Exception during handshake
ERROR [SecureSocket] 2 Dec 2019 11:43:28.126 :  System.IO.IOException: Socket closed before handshake is complete (2)
ERROR [SecureSocket] 2 Dec 2019 11:43:28.126 :     at v1AnLrTRwa7HN83E1Wy.heEfkmTX7TaifMreut8.E3xd2hPVmw6(IAsyncResult )
DEBUG [SocketController] 2 Dec 2019 11:43:28.169 : FTPConnection.1 Dispose()
DEBUG [SocketController] 2 Dec 2019 11:43:28.170 : FTPConnection.1 CloseConnection(e=null)

1 Answer

0 votes
by (51.1k points)
If it works when you comment out the line then it's likely that the server doesn't support either of the cipher-suites on that line and is dropping the connection because the client isn't offering any acceptable cipher-suites.

Categories

...