cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Upload Misbehaving

From: von <vb_nov_at_yahoo.com>
Date: Wed, 7 May 2008 05:39:57 -0700 (PDT)

Hi Dan, Thanks for the concern, all the values I sent are dummies. Here's what I got using HTTP1.0. I got a "Speed Upload" now but still no uploaded file. The cookie is being created in the server though. curl -o c:\temp\login.out -u username:password  -T c:\temp\file2upload.log securedURL  -k -b FDX securedURL/cookie.dat -0 -v * About to connect() to securedURL port 443 (#0) *   Trying theIPAddress... connected * Connected to securedURL (theIPAddress) port 443 (#0) * Server auth using Basic with user 'username' > PUT /sqr1%2Elog HTTP/1.0 > Authorization: Basic ZmdwX3Bzb2Z0OjFBbWVyaWNh > User-Agent: curl/7.18.1 (i386-pc-win32) libcurl/7.18.1 OpenSSL/0.9.8g zlib/1.2 .3 > Host: securedURL > Accept: */* > Content-Length: 577 > } [data not shown]   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current                                  Dload  Upload   Total   Spent    Left  Speed 100   577    0     0  100   577      0    795 --:--:-- --:--:-- --:--:--   795< HTTP/1.1 200 OK Why is it still HTTP 1.1 here? Based from your comment it's still 200 OK with Speed Upload but no data in the server. < Date: Wed, 07 May 2008 12:28:31 GMT < Server: SecureTransport/4.7 * Added cookie FDX="76506c595a66484e3653496c65365a4f4b364f447a673d3d" for domain  securedURL, path /, expire 0 < Set-Cookie: FDX=76506c595a66484e3653496c65365a4f4b364f447a673d3d; path=/; Secu re < Accept-Ranges: bytes < Expires: Thu, 01 Jan 1970 00:00:00 GMT < Features: CHPWD;RTCK;STCK;ASC;DNDISP < Connection: close < Content-Type: text/plain; charset=UTF-8 < { [data not shown] * SSLv3, TLS alert, Client hello (1): { [data not shown] 100   611    0    34  100   577     36    617 --:--:-- --:--:-- --:--:--     0* Closing connection #0 * SSLv3, TLS alert, Client hello (1): } [data not shown] * About to connect() to securedURL port 443 (#0) *   Trying theIPAddress... connected * Connected to securedURL (theIPAddress) port 443 (#0) * Server auth using Basic with user 'username' > PUT /cookie.dat HTTP/1.0 > Authorization: Basic ZmdwX3Bzb2Z0OjFBbWVyaWNh > User-Agent: curl/7.18.1 (i386-pc-win32) libcurl/7.18.1 OpenSSL/0.9.8g zlib/1.2 .3 > Host: securedURL > Accept: */* > Cookie: FDX=76506c595a66484e3653496c65365a4f4b364f447a673d3d > * Empty reply from server * Connection #0 to host securedURL left intact curl: (52) Empty reply from server * Closing connection #0 * SSLv3, TLS alert, Client hello (1):   ----- Original Message ---- From: Dan Fandrich <dan@coneharvesters.com> To: curl-users@cool.haxx.se Sent: Wednesday, May 7, 2008 12:07:58 AM Subject: Re: Upload Misbehaving On Tue, May 06, 2008 at 04:07:09PM -0700, von wrote: > I'm using 7.18.1 with ssl support. This is all I got when I ran the code: > If you will notice there is a message that says: Connection died, retrying a > fresh connect. > > And about the other computer, same exit code but can always upload. Tried that > a hundred times already. What curl options did you use?  Note also that your user and and password were in the log you sent--you'll want to change it ASAP. > * Server auth using Basic with user 'username' > > PUT /test%2Etxt HTTP/1.1 > > Authorization: Basic ZmdwX3Bzb2Z0OjFBbWVyaWNh > > User-Agent: curl/7.18.1 (i386-pc-win32) libcurl/7.18.1 OpenSSL/0.9.8g zlib/ > 1.2 > .3 > > Host: theUrl > > Accept: */* > > Content-Length: 3 > > Expect: 100-continue > > > < HTTP/1.1 200 OK This is odd. The server is replying with a 200 OK code even though it never received the data. That doesn't make sense to me.  It should reply with a 100 Continue code and then wait for the actual data to be sent. > < Date: Tue, 06 May 2008 23:00:00 GMT > < Server: SecureTransport/4.7 > * Added cookie FDX="75415136647a71397535636a50426a714444474748773d3d" for > domain >  theUrl, path /, expire 0 > < Set-Cookie: FDX=75415136647a71397535636a50426a714444474748773d3d; path=/; > Secu > re > < Accept-Ranges: bytes > < Expires: Thu, 01 Jan 1970 00:00:00 GMT > < Features: CHPWD;RTCK;STCK;ASC;DNDISP > < Transfer-Encoding: chunked > < Content-Type: text/plain; charset=UTF-8 > < > { [data not shown] >  % Total    % Received % Xferd  Average Speed  Time    Time    Time  Current >                                  Dload  Upload  Total  Spent    Left  Speed >  0    37    0    34    0    0      4      0 --:--:--  0:00:07 --:--:--    0* > Connection #0 to host theURL left intact > * Re-using existing connection! (#0) with host theURL > * Connected to theURL (170.146.188.96) port 443 (#0) > * Server auth using Basic with user 'username' > > PUT /a.dat HTTP/1.1 > > Authorization: Basic ZmdwX3Bzb2Z0OjFBbWVyaWNh > > User-Agent: curl/7.18.1 (i386-pc-win32) libcurl/7.18.1 OpenSSL/0.9.8g zlib/ > 1.2 > .3 > > Host: theURL > > Accept: */* > > Cookie: FDX=75415136647a71397535636a50426a714444474748773d3d > > Expect: 100-continue > > > * Connection died, retrying a fresh connect The server stopped responding for some reason, so curl tries again here. Maybe it got out of sync due to a broken response to the last request. It's odd that curl doesn't send a Content-Length or Transfer-Encoding: chunked header in this case--it does in the previous ones, and no header looks like an RFC violation to me.  Maybe the server is getting confused by that (although it should respond with a 400 or 411 error code instead). > * Closing connection #0 > * SSLv3, TLS alert, Client hello (1): > * Issue another request to this URL: 'https://theURL/a.dat' > * About to connect() to theURL port 443 (#0) > *  Trying 170.146.188.96... connected > * Connected to theURL (170.146.188.96) port 443 (#0) [...] > * Server auth using Basic with user 'username' > > PUT /a.dat HTTP/1.1 > > Authorization: Basic ZmdwX3Bzb2Z0OjFBbWVyaWNh > > User-Agent: curl/7.18.1 (i386-pc-win32) libcurl/7.18.1 OpenSSL/0.9.8g zlib/ > 1.2 > .3 > > Host: theURL > > Accept: */* > > Cookie: FDX=75415136647a71397535636a50426a714444474748773d3d > > Expect: 100-continue > > > * Empty reply from server Again, the server doesn't respond at all. Why not?  It's an HTTP/1.1 server so it knows about Expect headers. It should respond with a 100 Continue code or an error code. Maybe it's getting confused by the lack of Content-Length or Transfer-Encoding header again. > * Connection #0 to host theURL left intact > curl: (52) Empty reply from server > * Closing connection #0 > * SSLv3, TLS alert, Client hello (1): It sounds like the server is broken to me, but it doesn't look like curl is behaving properly, either.  Try forcing HTTP/1.0 mode with the -0 option as a workaround and see if that starts working. I'm not able to reproduce the missing Content-Length or Transfer-Encoding header problem on my machine.  Knowing the command-line options might make it easier to do that. >>> Dan -- http://www.MoveAnnouncer.com              The web change of address service           Let webmasters know that your web site has moved ____________________________________________________________________________________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Received on 2008-05-07