cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: cURL 'make test' fails on OpenBSD on PASV

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Tue, 11 Sep 2001 09:48:43 +0200 (MET DST)

On Mon, 10 Sep 2001, Heikki Korpela wrote:

[ the test ftp server worked with the OpenBSD ftp command ]

> (Login skipped, I use ~/.netrc. Want to add ftp(1) reference to the
> man page, BTW? :-) Free/Net/OpenBSDs documents .netrc on ftp(1),
> and at least OpenBSD has no individual netrc manpage.)

Added it just now. Thanks.

> > If it does work with the ordinary ftp client, the output from 'curl -v
> > ftp://localhost:8921/' would be very interesting to see.
>
> % curl --show-error --verbose --list --max-time 20 --connect-timeout 10
> ftp://localhost:8921/

[snip]

> * Connection (#0) left alive
> * Closing live connection (#0)

Ah, so it worked? Does it work the first time you try this, or is it random?
Or is it the timeout that makes it work?

BTW, if you cut off the --list option you'll see the same directory list your
ftp client got. --list causes NLST while a dir-URL only makes a LIST.

> [heikki_at_ip212-226-147-201|22:47:40|~] curl --show-error --verbose --list
> ftp://localhost:8921/

[snip]

> > PASV
> < 227 Entering Passive Mode (127,0,0,1,34,218)
> * Connecting to localhost (127.0.0.1) port 8922
> * Connected the data stream!
> > TYPE A
> < 200 I modify TYPE as you wanted
> > NLST
> < 150 here comes a directory
> * Getting file with size: -1
> file
> with space
> fake
> ..
> ..
> funny
> README
> [hangs for at least 20 minutes]

It does indeed point to some problem with the perl ftp server code. I cleaned
it up a bit and checked in an updated version, it would be cool if you could
try it out:

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/curl/curl/tests/ftpserver.pl?rev=1.20&content-type=text/vnd.viewcvs-markup

-- 
    Daniel Stenberg -- curl groks URLs -- http://curl.haxx.se/
Received on 2001-09-11