cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-tracker Archives

[ curl-Bugs-3579064 ] multi interface blocking with certain ftp servers

From: SourceForge.net <noreply_at_sourceforge.net>
Date: Sun, 04 Nov 2012 10:06:26 -0800

Bugs item #3579064, was opened at 2012-10-22 01:36
Message generated for change (Comment added) made by bagder
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=100976&aid=3579064&group_id=976

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: ftp
Group: bad behaviour
>Status: Closed
>Resolution: Fixed
Priority: 6
Private: No
Submitted By: Guido Berhoerster (gberh)
Assigned to: Daniel Stenberg (bagder)
Summary: multi interface blocking with certain ftp servers

Initial Comment:
Using the multi interface (tested with libcurl 7.27.0 and 7.25.0
on openSUSE 12.2) libcurl blocks when talking to certain FTP
servers until a libcurl timeout is reached after a couple of
minutes. This is problematic because it freezes the whole
application and all other running transfers. Apparently the
problem is related to passive mode, i.e. happens after switching
to passive mode, but only for certain hosts as for the vast
majority it works fine.
After tracing it with gdb it seems that libcurl gets
stuck in the while loop in ftp_easy_statemach() calling
Curl_pp_easy_statemach() -> Curl_socket_check() -> poll()
repeatedly until a timeout in Curl_pp_easy_statemach() is
reached. A minimal example (adapted from multi-app.c) that
connects to a server triggering the problem is attached. It
produces the following verbose output:

----8<----
ping
ping
ping
ping
ping
ping
ping
* About to connect() to ftp.caudium.net port 21 (#0)
* Trying 193.218.105.12...
ping
ping
ping
ping
* Connected to ftp.caudium.net (193.218.105.12) port 21 (#0)
* Connected to ftp.caudium.net (193.218.105.12) port 21 (#0)
ping
< 220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
< 220-You are user number 2 of 50 allowed.
< 220-Local time is now 09:03. Server port: 21.
< 220-Only anonymous FTP is allowed here
< 220 You will be disconnected after 15 minutes of inactivity.
> USER anonymous
ping
< 230-############################################################################
< 230-
< 230- W E L C O M E A S S O C I A T I O N K A Z A R F T P S E R V E R
< 230-
< 230-############################################################################
< 230-
< 230-This public FTP is repository of some OpenSource Projects and also a
< 230-public library.
< 230-
< 230-Please notice that bandwith is limited globaly not by sessions.
< 230-If you'd like to have more bandwith, please peer with us using Public IX.
< 230-To see where we can peer, please see http://as35189.net/, or have a look
< 230-at Panap, PouIX and GeIX IX pages.
< 230-
< 230-Also see our web site : http://kazar.net/
< 230-
< 230-Thanks
< 230-
< 230- Association KAZAR Team
< 230-
< 230 Anonymous user logged in
> PWD
ping
< 257 "/" is your current location
* Entry path is '/'
> CWD caudium
ping
< 250 OK. Current directory is /caudium
> CWD source
ping
< 250 OK. Current directory is /caudium/source
> EPSV
* Connect data stream passively
ping
< 229 Extended Passive mode OK (|||60138|)
* Trying 193.218.105.12...
* Connecting to 193.218.105.12 (193.218.105.12) port 60138
> TYPE A
< 200 TYPE is now ASCII
> LIST
* server response timeout
* Failure sending ABOR command: Timeout was reached
* Closing connection #0
---->8----

----------------------------------------------------------------------

Comment By: Daniel Stenberg (bagder)
Date: 2012-11-04 10:06

Message:
Thanks for the report, this problem is now fixed in the git repository.

To try it out, you either checkout/update your git clone:
http://curl.haxx.se/source.html

or you try tomorrow's daily snapshot: http://curl.haxx.se/snapshots/

----------------------------------------------------------------------

Comment By: Daniel Stenberg (bagder)
Date: 2012-10-29 15:20

Message:
Thanks for your report, I've managed to repeat the problem...

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=100976&aid=3579064&group_id=976
Received on 2012-11-04

These mail archives are generated by hypermail.

donate! Page updated January 05, 2012.
web site info

File upload with ASP.NET