[Solved] command line curl https doesnt work

Problems with the Windows version of XAMPP, questions, comments, and anything related.

[Solved] command line curl https doesnt work

Postby fourchette » 20. January 2009 07:38

Hi there,

I had a look around the forum using search function with no luck (or maybe i'm too dumb to understand them :p)

Notice: this question is **NOT** related to php at all.

I am trying to make .bat file to download a file located on https.

The line I use is similar to

Code: Select all
curl --insecure -u 'mylogin:mypass'  https://example.com/myfile.tar.gz > myfile.tar.gz


I use to work with this on linux Ubuntu. It works fine in this environment.

Since I use xampp for windows on my laptop, and since
curl.exe
libeay32.dll
ssleay32.dll


are all bundled in c:\xampp\apache\bin\ I thought it should work ok. (got that idea from curl web page => http://curl.haxx.se/docs/faq.html#Where ... y_of_LIBEA)

However it does not. curl throws a nasty

Code: Select all
C:\xampp\apache\bin>curl --insecure -u 'mylogin:mypass'  https://example.com/myfile.tar.gz > myfile.tar.gz

curl: (1) Protocol https not supported or disabled in libcurl



and indeed, it does seem that https isn't supported:

Code: Select all
C:\xampp\apache\bin>curl -V
curl 7.18.2 (i586-pc-mingw32msvc) libcurl/7.18.2 zlib/1.2.3
Protocols: tftp ftp telnet dict ldap http file
Features: Largefile libz



What's wrong? Since I load curl.exe while being in the very directory containing both libeay32.dll and ssleay32.dll, if curl.exe would require them, they would be loaded right? (and btw, I tried copy-paste in c:\windows\system32 and rebooting windows => doesn't work either

Anyone having an idea?
Last edited by fourchette on 20. January 2009 08:53, edited 1 time in total.
fourchette
 
Posts: 3
Joined: 20. January 2009 07:18

Re: command line curl https doesnt work

Postby Wiedmann » 20. January 2009 07:57

What's wrong?

The curl.exe in the XAMPP package is build without SSL support. If you need SSL, just go to the Curl hompage and download one with SSL support.

(BTW: I don't know, why there is this curl.exe in XAMPP since 1.7.0... The Curl PHP-Extension in XAMPP is build with SSL support.)
Wiedmann
AF Moderator
 
Posts: 17102
Joined: 01. February 2004 12:38
Location: Stuttgart / Germany


Re: command line curl https doesnt work

Postby fourchette » 20. January 2009 08:46

wow !!!
that is fast support !!!

i'm impressed guys :mrgreen: :mrgreen: :mrgreen:

Just one small notes to our Windows friends btw
of course the single quote thing didn't work on windows (unlike linux). double quote need to be used instead :

BAD: :(

Code: Select all
curl --insecure -u 'mylogin:mypass'  https://example.com/myfile.tar.gz > myfile.tar.gz


GOOD: :) :) :)

Code: Select all
curl --insecure -u "mylogin:mypass"  https://example.com/myfile.tar.gz > myfile.tar.gz



I love you guys! it worked like a charm.

where's the "fixed" button here ? :)
fourchette
 
Posts: 3
Joined: 20. January 2009 07:18

Re: command line curl https doesnt work

Postby Izzy » 20. January 2009 08:50

where's the "fixed" button here ?

Just edit your first post and add fixed or solved to the topic title.
Job done!

Good luck and happy curling. :D
Izzy
 
Posts: 3344
Joined: 25. April 2006 17:06

Re: command line curl https doesnt work

Postby fourchette » 20. January 2009 08:53

Wiedmann wrote:(BTW: I don't know, why there is this curl.exe in XAMPP since 1.7.0...


don't know either. I found it accidentally ad thougtht it might work without installing anything.

My xampp is not that old (about 6~8 months i'd say), it might be related.

I am not sure where xampp version number is stored but this might answer the question:

Code: Select all
C:\xampp>more xampp-changes.txt
04. Jul 2008 XAMPP 1.6.7
- Upgrade phpMyAdmin 2.11.7
- Upgrade ... bla bla bla bla ...
fourchette
 
Posts: 3
Joined: 20. January 2009 07:18


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 158 guests