cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: connecting to ftps with certificate?

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Mon, 16 Jun 2008 13:10:54 -0700

On Mon, Jun 16, 2008 at 01:45:07PM -0500, Lukasz Szybalski wrote:
> so I finally figured that:
>
> ftp> cd XXXX.YYYY/#E2
> 250 Currently to user XXXX.YYYY with class #E2
> cd XXXX.YYYY/#E2/
> 550 Invalid directory.
>
> so with quote I was able to do
> curl -E certkey.pem -k -v -u user:pass
> ftp://usa.ftptls.edisrvcs.com/xxx.yyy/ --ftp-ssl --quote "cwd /#E2" -T
> testfile.txt

As I mentioned, this method could cause problems. Better to use what
Daniel suggested.

> so now I just need to download files.
>
> Would you have a quick bash script that parses list of files and then
> downloads them?

There are some perl scripts that do that at
http://curl.haxx.se/docs/programs.html

> Also, I have downloaded one of the files, but the content was not text
> "@@!...." is there some kind of flag I have to set to maybe get files
> as text or...?

You probably need to specify text transfers in the URL. Try appending
";type=A" to your URL, and note that curl doesn't completely support
text conversion (it's listed as a known bug).

>>> Dan

-- 
http://www.MoveAnnouncer.com              The web change of address service
          Let webmasters know that your web site has moved
Received on 2008-06-16