cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Re: Passing spaces to Mailchimp with JSON & Windows

From: PERDRIAU Gilles DSIC BSSU <gilles.perdriau_at_interieur.gouv.fr>
Date: Tue, 17 Dec 2013 15:27:04 +0100

Hi,

Sorry but this become difficult to resolve this problem.
I think that the best solution is to use another customer SFTP

C:\Program Files\cURL\bin>*curl --insecure -v -o zz -u exfb:
sftp://www.xxx.yyy.zzz//QGAT/logexp/log/log.dat_20131215 --key
"d:\sas\CLES SSH\CU
RL\curl_private_openssh_key" --pubkey "d:\sas\CLES
SSH\CURL\curl_public_openssh_key.pem"*
* About to connect() to 1www.xxx.yyy.zzz port 22 (#0)
* Trying www.xxx.yyy.zzz...
* Adding handle: conn: 0x3db810
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x3db810) send_pipe: 1, recv_pipe: 0
   % Total % Received % Xferd Average Speed Time Time Time
Current
                                  Dload Upload Total Spent Left
Speed
   0 0 0 0 0 0 0 0 --:--:-- --:--:--
--:--:-- 0* Connected to www.xxx.yyy.zzz (www.xxx.yyy.zzz) port 22 (#0)
* SSH MD5 fingerprint: 4441fb379f0e27e7fef7be71e733f832
   0 0 0 0 0 0 0 0 --:--:-- --:--:--
--:--:-- 0* SSH authentication methods available: publickey,password,key
board-interactive
* Using ssh public key file d:\sas\CLES SSH\CURL\curl_public_openssh_key.pem
* Using ssh private key file d:\sas\CLES SSH\CURL\curl_private_openssh_key
*SSH public key authentication failed: Invalid public key
* Failure connecting to agent
* Authentication failure
   0 0 0 0 0 0 0 0 --:--:-- --:--:--
--:--:-- 0
   0 0 0 0 0 0 0 0 --:--:-- --:--:--
--:--:-- 0
* Closing connection 0
curl: (67) Authentication failure

C:\Program Files\cURL\bin>

Thanks for your help

Cordialement

Gilles PERDRIAU

Ministère de l'intérieur
SG - DSIC - SDI - Bureau des Services et des Infrastructures Transverses

Tél : 01.61.44.26.77
Port: 06.64.42.38.61

Mail : gilles.perdriau_at_interieur.gouv.fr

-------- Message original --------
*Sujet: *[INTERNET] Re: Passing spaces to Mailchimp with JSON & Windows
*De : *Daniel Stenberg <daniel_at_haxx.se>
*Pour : *the curl tool <curl-users_at_cool.haxx.se>
*Date : *17/12/2013 11:47
> On Tue, 17 Dec 2013, Owen Watson wrote:
>
>> I'm trying to pass a JSON call to MailChimp via commandline Windows
>> and not
>> having much luck.
>
> I don't think this is much of a curl issue. curl sends what you tell
> it to send so you need to figure out what to send...
>
>> I'm using curl --insecure -d {JSON call}
>> https://us1.mailchimp.com/list/subscribe In the JSON call it works
>> fine if there's no spaces, as you'd expect, but as soon as you
>> introduce spaces, even if you replace them by + or %20 it falls over.
>
> You need to read up on their API on how the JSON is supposed to look
> like. I think JSON is rarely encoded. Are you possing not using any
> quotes around the data, like in your example shows here?
>

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-12-17