我們想使用 edtftpj/PRO 7.3.0 將 Filezilla 服務器 1.5.1 與 FTPS 顯式 TLS1.2 連接(edtftpj/PRO 支持 TLS 1.2 max)。
我在filezilla服務器中獲得了日志
FTP Session 51 127.0.0.1 [Trace] TLS handshakep: Received CLIENT HELLO
FTP Session 51 127.0.0.1 [Trace] tls_layer_impl::failure(-87)
FTP Session 51 127.0.0.1 [Error] GnuTLS error -87: No supported cipher suites have been found.
Java客戶端中的那個例外:
DEBUG [FTPControlSocket] 9 nov. 2022 17:29:48.861 : 220-FileZilla Server 1.5.1
DEBUG [FTPControlSocket] 9 nov. 2022 17:29:48.861 : 220 Please visit https://filezilla-project.org/
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:48.864 : DISABLE_CONTROL_SSL_CLOSURE=false
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:48.864 : DISABLE_CONTROL_WAIT_ON_CLOSE=false
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:48.865 : ALLOW_BASIC_CONSTRAINTS_IN_NON_CA=false
DEBUG [FTPControlSocket] 9 nov. 2022 17:29:48.865 : ---> AUTH TLS
DEBUG [FTPControlSocket] 9 nov. 2022 17:29:48.869 : 234 Using authentication type TLS.
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:48.869 : Starting SSL handshake on control socket
INFO [cryptix] 9 nov. 2022 17:29:48.990 : GLOBAL_TRACE=false
INFO [cryptix] 9 nov. 2022 17:29:48.990 : GLOBAL_DEBUG=false
INFO [cryptix] 9 nov. 2022 17:29:48.990 : GLOBAL_DEBUG_SLOW=false
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:49.065 : Caught: com.enterprisedt.net.puretls.SSLHandshakeFailedException
DEBUG [SSLFTPControlSocket] 9 nov. 2022 17:29:49.065 : Caught: com.enterprisedt.net.puretls.SSLHandshakeFailedException
ERROR 09-11-2022 17:29:49 com.enterprisedt.net.puretls.SSLPrematureCloseException: Short read - org.test.FtpUtilTest.downloadFileFTP(FtpUtilTest.java:174)
com.enterprisedt.net.puretls.SSLHandshakeFailedException: com.enterprisedt.net.puretls.SSLPrematureCloseException: Short read
at com.enterprisedt.net.puretls.j.a(SSLConn.java:164)
at com.enterprisedt.net.puretls.SSLSocket.handshake(SSLSocket.java:261)
at com.enterprisedt.net.ftp.ssl.SSLFTPControlSocket.c(SSLFTPControlSocket.java:322)
at com.enterprisedt.net.ftp.ssl.SSLFTPClient.auth(SSLFTPClient.java:1569)
客戶端代碼(添加所有密碼)
ftpClient = new SSLFTPClient();
ftpClient.setRemoteHost(host);
ftpClient.setRemotePort(port);
//add all ciphers
ftpClient.disableAllCipherSuites();
ftpClient.enableCipherSuites(SSLFTPCipherSuite.getCipherSuites());
ftpClient.setValidateServer(false);
ftpClient.connect();
ftpClient.auth(SSLFTPClient.AUTH_TLS); // -> Excecption
uj5u.com熱心網友回復:
這可能是因為 FileZilla Server 使用的是 ECC 證書,而 edtFTPj/PRO 尚不支持該證書。嘗試使用 RSA 證書配置服務器。
轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/531633.html
