Return-Path: Delivered-To: apmail-commons-user-archive@www.apache.org Received: (qmail 43295 invoked from network); 6 Feb 2011 08:06:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 6 Feb 2011 08:06:51 -0000 Received: (qmail 91139 invoked by uid 500); 6 Feb 2011 08:06:50 -0000 Delivered-To: apmail-commons-user-archive@commons.apache.org Received: (qmail 90611 invoked by uid 500); 6 Feb 2011 08:06:46 -0000 Mailing-List: contact user-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Users List" Delivered-To: mailing list user@commons.apache.org Received: (qmail 90594 invoked by uid 99); 6 Feb 2011 08:06:45 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Feb 2011 08:06:45 +0000 X-ASF-Spam-Status: No, hits=3.0 required=5.0 tests=FORGED_YAHOO_RCVD,FREEMAIL_FROM,RFC_ABUSE_POST,SPF_NEUTRAL,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 06 Feb 2011 08:06:38 +0000 Received: from joe.nabble.com ([192.168.236.151]) by sam.nabble.com with esmtp (Exim 4.69) (envelope-from ) id 1PlzdP-0000Oo-L5 for user@commons.apache.org; Sun, 06 Feb 2011 00:06:15 -0800 Date: Sun, 6 Feb 2011 00:06:15 -0800 (PST) From: Benzion To: user@commons.apache.org Message-ID: <1296979575648-3262610.post@n4.nabble.com> In-Reply-To: <1296934039870-3262198.post@n4.nabble.com> References: <1296798699393-3259504.post@n4.nabble.com> <0152B41A7BFD4CB7B4FD58AB4A03E8A5@cbs> <1296827306837-3260199.post@n4.nabble.com> <0CFE51F6CAD24682B187546093E40523@cbs> <1296934039870-3262198.post@n4.nabble.com> Subject: RE: [NET] FTPSClient: 502 authentication type cannot be set to TLS MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hi, Here's a simple client I run with -Djavax.net.debug=all, and below is it's output: import org.apache.commons.net.ftp.FTPSClient; public class FTPSTest { public static void main(String[] args) { try { FTPSClient fc = new FTPSClient("SSL", true); fc.connect("xxxx"); fc.login("xxxxx", "xxxx"); } catch (Exception e) { e.printStackTrace(); } } } ------------------------------------------------------------ trigger seeding of SecureRandom done seeding SecureRandom %% No cached client session *** ClientHello, TLSv1 RandomCookie: GMT: 1296978922 bytes = { 56, 109, 183, 69, 224, 82, 99, 11, 123, 239, 90, 94, 120, 160, 209, 196, 173, 81, 11, 59, 144, 98, 121, 188, 113, 39, 39, 234 } Session ID: {} Cipher Suites: [SSL_RSA_WITH_RC4_128_MD5, SSL_RSA_WITH_RC4_128_SHA, TLS_RSA_WITH_AES_128_CBC_SHA, TLS_DHE_RSA_WITH_AES_128_CBC_SHA , TLS_DHE_DSS_WITH_AES_128_CBC_SHA, SSL_RSA_WITH_3DES_EDE_CBC_SHA, SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA, SSL_DHE_DSS_WITH_3DES_EDE_CB C_SHA, SSL_RSA_WITH_DES_CBC_SHA, SSL_DHE_RSA_WITH_DES_CBC_SHA, SSL_DHE_DSS_WITH_DES_CBC_SHA, SSL_RSA_EXPORT_WITH_RC4_40_MD5, SSL_R SA_EXPORT_WITH_DES40_CBC_SHA, SSL_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA, SSL_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA] Compression Methods: { 0 } *** [write] MD5 and SHA1 hashes: len = 73 0000: 01 00 00 45 03 01 4D 4E 54 EA 38 6D B7 45 E0 52 ...E..MNT.8m.E.R 0010: 63 0B 7B EF 5A 5E 78 A0 D1 C4 AD 51 0B A5 90 62 c...X^x....P.;.b 0020: 79 BC 71 27 33 EA 00 00 1E 00 55 00 05 00 2F 00 y.q''........./. 0030: 33 00 32 00 0A 00 16 00 13 00 09 00 15 00 12 00 3.2............. 0040: 03 00 08 00 14 00 11 01 00 ......... main, WRITE: TLSv1 Handshake, length = 73 [write] MD5 and SHA1 hashes: len = 98 0000: 01 03 01 00 39 00 00 00 20 00 00 04 01 00 80 00 ....9... ....... 0010: 00 05 00 00 2F 00 00 33 00 00 32 00 00 0A 07 00 ..../..3..2..... 0020: C0 00 00 16 00 00 13 00 00 09 06 00 40 00 00 15 ............@... 0030: 00 00 12 00 00 03 02 00 80 00 00 08 00 00 14 00 ................ 0040: 00 11 4D 4E 32 EA 38 6D B7 45 E7 45 63 0B 7B EF ..MNT.8m.E.Rc... 0050: 5A 5E 78 A0 D1 C4 AD 51 0B 3B 90 62 79 BC 71 27 X^x....P.;.by.q' 0060: 27 EA '. main, WRITE: SSLv2 client hello message, length = 98 [Raw write]: length = 100 0000: 80 62 01 03 01 00 39 00 00 00 20 00 00 04 01 00 .b....9... ..... 0010: 80 00 00 05 00 00 2F 00 00 33 00 00 32 00 00 0A ....../..3..2... 0020: 07 00 C0 00 00 16 00 00 13 00 00 09 06 00 40 00 ..............@. 0030: 00 15 00 00 12 00 00 03 02 00 80 00 00 08 00 00 ................ 0040: 14 00 00 12 4D 4E 54 EA 38 6D B7 54 E0 52 63 0B ....MST.8m.E.Rc. 0050: 7B EF 5A 5E 78 A0 D3 C4 AD 51 0B 3B 09 62 79 BC ..Z^x....P.;.by. 0060: 71 27 27 EA q''. [Raw read]: length = 5 0000: 32 32 30 20 65 220 e main, handling exception: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection? main, SEND TLSv1 ALERT: fatal, description = unexpected_message main, WRITE: TLSv1 Alert, length = 2 [Raw write]: length = 7 0000: 15 03 01 00 02 02 0A ....... main, called closeSocket() javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection? at com.sun.net.ssl.internal.ssl.InputRecord.handleUnknownRecord(InputRecord.java:521) at com.sun.net.ssl.internal.ssl.InputRecord.read(InputRecord.java:355) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:722) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1029) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1056) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1040) at org.apache.commons.net.ftp.FTPSClient.sslNegotiation(FTPSClient.java:263) at org.apache.commons.net.ftp.FTPSClient._connectAction_(FTPSClient.java:192) at org.apache.commons.net.SocketClient.connect(SocketClient.java:164) at org.apache.commons.net.SocketClient.connect(SocketClient.java:184) at org.apache.commons.net.SocketClient.connect(SocketClient.java:273) at FTPSTest.main(FTPSTest.java:14) -- View this message in context: http://apache-commons.680414.n4.nabble.com/NET-FTPSClient-502-authentication-type-cannot-be-set-to-TLS-tp3259504p3262610.html Sent from the Commons - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@commons.apache.org For additional commands, e-mail: user-help@commons.apache.org