curl / Mailing Lists / curl-users / Single Mail

curl-users

How to up one file to drftpd (how to use --ftp-pret )

From: mars zhang <6671605_at_gmail.com>
Date: Mon, 26 Dec 2016 10:02:45 +0800

I can use FileZilla Client to up one file to drftpd successfully but I use
curl command
*curl -T mycc2.txt --ftp-ssl --insecure --ftp-pret
 ftp://myabc:myabc123ABC@192.168.14.1:2121/123/mycc2.txt
<ftp://myabc:myabc123ABC@192.168.14.1:2121/123/mycc2.txt> *--trace-ascii
output.txt
just timed out

output.txt is below
== Info: Trying 192.168.14.1... == Info: TCP_NODELAY set == Info: Connected
to 192.168.14.1 (192.168.14.1) port 2121 (#0) <= Recv header, 55 bytes
(0x37) 0000: 220 DrFTPD 3.2.0 https://github.com/drftpd-ng/drftpd3 => Send
header, 10 bytes (0xa) 0000: AUTH SSL <= Recv header, 25 bytes (0x19) 0000:
234 auth SSL successful == Info: Cipher selection:
ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH == Info: TLSv1.2
(OUT), TLS header, Certificate Status (22): => Send SSL data, 5 bytes (0x5)
0000: ..... == Info: TLSv1.2 (OUT), TLS handshake, Client hello (1): =>
Send SSL data, 512 bytes (0x200) 0000: ........y..."f......}Pu...>..g"U...;
@....0.,.(.$.............k. 0040:
j.i.h.9.8.7.6.........2...*.&.......=.5.../.+.'.#.............g. 0080:
@.?.>.3.2.1.0.........E.D.C.B.1.-.).%.......<./...A............. 00c0:
............3........................................... ....... 0100:
................................................................ 0140:
................................................................ 0180:
................................................................ 01c0:
................................................................ <= Recv
SSL data, 5 bytes (0x5) 0000: ..../ == Info: TLSv1.2 (IN), TLS handshake,
Server hello (2): <= Recv SSL data, 81 bytes (0x51) 0000:
...M..X`w...l.L.B.....1...a9._..Uz..>E X`w.[.......`!y.....y.... 0040:
.)-...~.+........ == Info: TLSv1.2 (IN), TLS handshake, Certificate (11):
<= Recv SSL data, 326 bytes (0x146) 0000:
...B..?..<0..80.........W...0...*.H.=.....0.1.0...U....drftpd0.. 0040:
.161220011518Z..170320011518Z0.1.0...U....drftpd0Y0...*.H.=....* 0080:
.H.=....B..#........\~T.....{..>..!].....z2.t..[\...)......u..KE 00c0:
...,C.(.....!0.0...U......Wn........N[.;.l2.E.0...*.H.=......H.0 0100: E.
S^..48.A......*....o...x.D..V\k..!....@.`..-.`.I..h4....:.... 0140: .9..#2
== Info: TLSv1.2 (IN), TLS handshake, Server key exchange (12): <= Recv SSL
data, 148 bytes (0x94) 0000: .......A.Sy.ce.iO..ld.UT..._._at_r
....ip...*.!f,.....Z..9p3j..;.~{ 0040:
............G0E.!.......P........D...^".CB.A.*..... .`....c.jw;. 0080:
..7p.^].R.:......... == Info: TLSv1.2 (IN), TLS handshake, Server finished
(14): <= Recv SSL data, 4 bytes (0x4) 0000: .... => Send SSL data, 5 bytes
(0x5) 0000: ....F == Info: TLSv1.2 (OUT), TLS handshake, Client key
exchange (16): => Send SSL data, 70 bytes (0x46) 0000:
...BA...r../.y.........0.%9^.F. bS^..K vARYp.(o/..f...g.Z......; 0040:
...7K. => Send SSL data, 5 bytes (0x5) 0000: ..... == Info: TLSv1.2 (OUT),
TLS change cipher, Client hello (1): => Send SSL data, 1 bytes (0x1) 0000:
. => Send SSL data, 5 bytes (0x5) 0000: ....( == Info: TLSv1.2 (OUT), TLS
handshake, Finished (20): => Send SSL data, 16 bytes (0x10) 0000:
.....V..#..a1..F <= Recv SSL data, 5 bytes (0x5) 0000: ..... == Info:
TLSv1.2 (IN), TLS change cipher, Client hello (1): <= Recv SSL data, 1
bytes (0x1) 0000: . <= Recv SSL data, 5 bytes (0x5) 0000: ....( == Info:
TLSv1.2 (IN), TLS handshake, Finished (20): <= Recv SSL data, 16 bytes
(0x10) 0000: ....2v."...?...Q == Info: SSL connection using TLSv1.2 /
ECDHE-ECDSA-AES128-GCM-SHA256 == Info: Server certificate: == Info:
subject: CN=drftpd == Info: start date: Dec 20 01:15:18 2016 GMT == Info:
expire date: Mar 20 01:15:18 2017 GMT == Info: issuer: CN=drftpd == Info:
SSL certificate verify result: self signed certificate (18), continuing
anyway. => Send SSL data, 5 bytes (0x5) 0000: ....& => Send header, 14
bytes (0xe) 0000: USER myabc <= Recv SSL data, 5 bytes (0x5) 0000: ....< <=
Recv header, 36 bytes (0x24) 0000: 331 Password required for myabc => Send
SSL data, 5 bytes (0x5) 0000: ...., => Send header, 20 bytes (0x14) 0000:
PASS myabc123ABC <= Recv SSL data, 5 bytes (0x5) 0000: ....s <= Recv
header, 7 bytes (0x7) 0000: 230- <= Recv header, 47 bytes (0x2f) 0000: 230-
Welcome to the future of FXP:ing <= Recv header, 39 bytes (0x27) 0000: 230-
___ _____________ ___ <= Recv header, 40 bytes (0x28) 0000: 230- / _ \____/
__/_ __/ _ \/ _ \ <= Recv header, 40 bytes (0x28) 0000: 230- / // / __/ _/
/ / / ___/ // / <= Recv header, 39 bytes (0x27) 0000: 230- /____/_/ /_/ /_/
/_/ /____/ <= Recv header, 47 bytes (0x2f) 0000: 230- DistRibuted FTP
Daemon <= Recv header, 47 bytes (0x2f) 0000: 230- http://drftpd.org <= Recv
header, 7 bytes (0x7) 0000: 230- <= Recv header, 34 bytes (0x22) 0000: 230
user logged in successfully. => Send SSL data, 5 bytes (0x5) 0000: .... =>
Send header, 8 bytes (0x8) 0000: PBSZ 0 <= Recv SSL data, 5 bytes (0x5)
0000: ....* <= Recv header, 18 bytes (0x12) 0000: 200 Command okay => Send
SSL data, 5 bytes (0x5) 0000: .... => Send header, 8 bytes (0x8) 0000: PROT
P <= Recv SSL data, 5 bytes (0x5) 0000: ....* <= Recv header, 18 bytes
(0x12) 0000: 200 Command okay => Send SSL data, 5 bytes (0x5) 0000: .....
=> Send header, 5 bytes (0x5) 0000: PWD <= Recv SSL data, 5 bytes (0x5)
0000: ....6 <= Recv header, 30 bytes (0x1e) 0000: 257 "/" is current
directory == Info: Entry path is '/' => Send SSL data, 5 bytes (0x5) 0000:
....! => Send header, 9 bytes (0x9) 0000: CWD 123 == Info: ftp_perform ends
with SECONDARY: 0 <= Recv SSL data, 5 bytes (0x5) 0000: ....7 <= Recv
header, 31 bytes (0x1f) 0000: 250 Directory changed to /123 => Send SSL
data, 5 bytes (0x5) 0000: ....- => Send header, 21 bytes (0x15) 0000: PRET
STOR mycc2.txt <= Recv SSL data, 5 bytes (0x5) 0000: ....> <= Recv header,
38 bytes (0x26) 0000: 200 OK, planning for upcoming upload => Send SSL
data, 5 bytes (0x5) 0000: ..... => Send header, 6 bytes (0x6) 0000: EPSV ==
Info: Connect data stream passively <= Recv SSL data, 5 bytes (0x5) 0000:
....6 <= Recv header, 30 bytes (0x1e) 0000: 502 Command not implemented. ==
Info: Failed EPSV attempt. Disabling EPSV => Send SSL data, 5 bytes (0x5)
0000: ..... => Send header, 6 bytes (0x6) 0000: PASV <= Recv SSL data, 5
bytes (0x5) 0000: ....v <= Recv header, 41 bytes (0x29) 0000: 227- Using
slave2 for upcoming transfer <= Recv header, 53 bytes (0x35) 0000: 227
Entering Passive Mode (192,168,14,128,234,248). == Info: Trying
192.168.14.128... == Info: TCP_NODELAY set == Info: Connecting to
192.168.14.128 (192.168.14.128) port 60152 == Info: connect to
192.168.14.128 port 2121 failed: Timed out == Info: Failed to connect to
192.168.14.1 port 2121: Timed out == Info: Closing connection 0 => Send SSL
data, 5 bytes (0x5) 0000: ..... == Info: TLSv1.2 (OUT), TLS alert, Client
hello (1): => Send SSL data, 2 bytes (0x2) 0000: ..

why?
my curl version is 7.51

FileZilla : set Transfer Mode "Allow fall back to other transfer on
failure" is successful to up one file .and failed for not check this;

-------------------------------------------------------------------
List admin: https://cool.haxx.se/list/listinfo/curl-users
FAQ: https://curl.haxx.se/docs/faq.html
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2016-12-26