cURL / Mailing Lists / curl-users / Single Mail

curl-users

HTTPS Put using Curl

From: <anthony.2.petty_at_bt.com>
Date: Tue, 20 May 2003 09:18:03 +0100

Hello,

   I am trying to put a file on a sever using curl when using the command

curl -T <file name> -E <pemfile:password> -v <https server connection>

We get the error messages below

* About to connect() to xxxxxxxxx:443
* Connected to xxxxxxxxxxxxxxxxxxx port 443
* SSL: error:00000001:lib(0):func(0):reason(1)
* Closing connection #0
curl: (35) SSL: error:00000001:lib(0):func(0):reason(1)

When connecting with the -k option all works ok see below, but the -k option
is insecure and could lead to information being hacked etc..

curl -T <file name> -E <pemfile:password> -v -k <https server connection>
* About to connect() to xxxxxxxxxxxx:443
* Connected to xxxxxxxxxxxxxxxxxxxx port 443
* SSL connection using RC4-MD5
* Server certificate:
* subject: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
* start date: 2002-11-05 07:40:01 GMT
* expire date: 2003-11-05 07:50:01 GMT
* common name: xxxxxxxxxxxxxxxxxx (matched)
* issuer: /emailAddress=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> PUT /bthcweb/paul%2Ein HTTP/1.1
User-Agent: curl/7.10.4 (win32) libcurl/7.10.4 OpenSSL/0.9.7b zlib/1.1.4
Host: xxxxxxxxxxxxxxxxxxxxxxxxxx
Pragma: no-cache
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */*
Content-Length: 9

  % Total % Received % Xferd Average Speed Time
Curr.
                                 Dload Upload Total Current Left
Speed
100 9 0 0 100 9 0 4 0:00:01 0:00:01 0:00:00
0
* Connection #0 left intact
* Closing connection #0

Below is the output from the server we are sending the information to

 #Software: Microsoft Internet Information Services 5.0
#Version: 1.0
#Date: 2003-05-19 01:14:17
#Fields: date time c-ip cs-username s-ip s-port cs-method cs-uri-stem
cs-uri-query sc-status cs(User-Agent)
2003-05-19 08:29:10 xxxxxxxxxxxx - xxxxxxxxxxxxx 443 PUT /bthcweb/paul.in -
201 curl/7.10.4+(win32)+libcurl/7.10.4+OpenSSL/0.9.7b+zlib/1.1.4
2003-05-19 09:12:23 xxxxxxxxxxxx - xxxxxxxxxxxxx 443 PUT /bthcweb/paul.in -
200 curl/7.10.4+(win32)+libcurl/7.10.4+OpenSSL/0.9.7b+zlib/1.1.4
2003-05-19 09:23:43 xxxxxxxxxxxx - xxxxxxxxxxxxx 443 PUT /bthcweb/paul.in -
403 curl/7.10.4+(win32)+libcurl/7.10.4+OpenSSL/0.9.7b+zlib/1.1.4
2003-05-19 10:14:56 xxxxxxxxxxxx - xxxxxxxxxxxxx 443 PUT /bthcweb/paul.in -
200 curl/7.10.4+(win32)+libcurl/7.10.4+OpenSSL/0.9.7b+zlib/1.1.4

The only difference I can see is the sc-status where 200 and 201 work
successfully and 403 is forbidden. Are there any other logs we can look in
for more information and is there another method of sending the file across
securely and checking the certificate to ensure all is ok.

Any help will be gratefully received

Regards

Anthony Petty

e-Business - Cardiff

BT Net 00 760 4411
Tel No: 029 2072 4411
Mobile: 07711 640587
Fax No:029 20724137
email: anthony.2.petty_at_bt.com
Mail PP: E/1/B, 84-85 Enterprise House, Adam St., Cardiff CF24 2XF

British Telecommunications plc
Registered office: 81 Newgate Street London EC1A 7AJ
Registered in England no. 1800000

This electronic message contains information from British Telecommunications
plc which may be privileged or confidential. The information is intended to
be for the use of the individual(s) or entity named above. If you are not
the intended recipient be aware that any disclosure, copying, distribution
or use of the contents of this information is prohibited. If you have
received this electronic message in error, please notify us by telephone or
email (to the numbers or address above) immediately.

-------------------------------------------------------
This SF.net email is sponsored by: ObjectStore.
If flattening out C++ or Java code to make your application fit in a
relational database is painful, don't do it! Check out ObjectStore.
Now part of Progress Software. http://www.objectstore.net/sourceforge
Received on 2003-05-20