cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Using curl https to Post Fixed-Length Text Data -- Unable to Get Response Data

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Mon, 23 Apr 2007 16:32:40 -0700

On Mon, Apr 23, 2007 at 04:11:08PM -0700, Rob Moretti wrote:
> This is the command string that works with the XML:
>
> curl -v https://cert.xyzcompany.com:99999 --cacert "cert.txt" -k --max-time
> 300
> -H "User-Agent:" -H "Host:" -H "Pragma:" -H "Accept:" -H "Content-Length:"
> -H "
> Content-Type:" -H "Expect:" -X "<?xml version=\"1.0\"
> encoding='UTF-8'?><!--" --
> data-binary "@myinputdata.xml" > myreplydata.xml
>
> The XML file starts with: --><Request version="3.0"
> xmlns=http://www.xyzcompany.com/schema...
>
> i.e., "-->" is appended to the beginning of the data to closeout the comment
> "<-- HTTP/1.1 -->" that results from the curl command.

Wow. No wonder you're having problems--this isn't an HTTP server you're
trying to talk to at all. Those commands completely disable all HTTP
headers and just send data to the server. You probably don't want curl
at all for this--try using 'stunnel' with the -c and -f options rather
than trying to make curl go through such contortions.

>>> Dan

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