curl-library
Re: HTTP
Date: Thu, 12 Jun 2003 10:08:57 +0200 (CEST)
On Wed, 11 Jun 2003 Vassilevich_Misha_at_emc.com wrote:
> I wrote Java clent program to talk to our server via https . I am creating
> HTTP header and BODY of the request myself of and simply enable SSL socket
> and send it as the string of the following format :
> curl = curl_easy_init();
> struct curl_slist *headers=NULL;
>
> headers = curl_slist_append(headers, "Content-Type: text/xml"); //customer
> header text/xml
> headers = curl_slist_append(headers, "EMCXMPUser: nasadmin");// define
> myself not in curl !!!
> headers = curl_slist_append(headers, "EMCXMPAction: mtr"); // define myself
> not in curl !!!
>
> curl_easy_setopt(curl, CURLOPT_POSTFIELDS,"/servlets/CelerraManager");
This path is set as part of the CURLOPT_URL field.
> curl_easy_setopt(curl, CURLOPT_POSTFIELDS,total.c_str() );
This should be the XML data. This option can only be set once, this latter
one overrides the previous one.
> curl_easy_setopt(curl, CURLOPT_URL," https:// <https://4> xxx.xxx.xxx");
This should be the full URL, not just the protocol and host name. This string
looks really wrong and confused. It should be similar to this:
"https://hostname.com/servlets/CelerraManager".
> I am getting error message number 60 all the time . Does anybody can spot
> what i am doing wrong . Will realy appriciate any response and corrections
> to my hybrid :)))))
Read this: http://curl.haxx.se/docs/sslcerts.html
-- Daniel Stenberg -- curl: been grokking URLs since 1998 ------------------------------------------------------- This SF.NET email is sponsored by: eBay Great deals on office technology -- on eBay now! Click here: http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5Received on 2003-06-12