Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 41595 invoked from network); 3 Nov 2010 08:43:18 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 3 Nov 2010 08:43:18 -0000 Received: (qmail 86688 invoked by uid 500); 3 Nov 2010 08:43:48 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 86522 invoked by uid 500); 3 Nov 2010 08:43:45 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 86514 invoked by uid 99); 3 Nov 2010 08:43:44 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 Nov 2010 08:43:44 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=FREEMAIL_FROM,HTML_MESSAGE,NORMAL_HTTP_TO_IP,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of douglas.linder@gmail.com designates 209.85.161.52 as permitted sender) Received: from [209.85.161.52] (HELO mail-fx0-f52.google.com) (209.85.161.52) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 03 Nov 2010 08:43:37 +0000 Received: by fxm12 with SMTP id 12so250445fxm.11 for ; Wed, 03 Nov 2010 01:43:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=YjOBQxzhqoW2JvZqXDyF+cUgBACl+rfW5TiV1nofDp4=; b=qr0jMEmvYkwNHelKbvVlW9CHhKy0eqzvFod/N/BGTRS2FeMJ5OF1x/yGHI/JgnwU9w ZPEVOeqpiV+hjCyd0NkmzxqklWLDAwE88lSWGp/ww1ANYkJrlufFisAVH1tF/MngTOQy xExAG07i1I3RdsxRT6BGhRL/iZ6IYSqjTBdoc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=dPmgMUWNWrulco7OEBn1Vi0LhUe64YrhheqbKDrxEUZmW0ibIS2ZwpGsQHpYBnnQeD MDBTXRMP5YmJOWod2+Jzi5miDJfb0lwCrdjmYltN0G5DhWRcCYWzIVrtlaemHSMvsYMJ 3xW9gDxeVz1y07pCnl2ilTQqi73LiIr1uoe/4= MIME-Version: 1.0 Received: by 10.223.97.13 with SMTP id j13mr3680792fan.146.1288773797047; Wed, 03 Nov 2010 01:43:17 -0700 (PDT) Received: by 10.223.102.75 with HTTP; Wed, 3 Nov 2010 01:43:17 -0700 (PDT) Date: Wed, 3 Nov 2010 16:43:17 +0800 Message-ID: Subject: Auth guide error? From: Doug To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=20cf3054a6155e6e680494220852 X-Virus-Checked: Checked by ClamAV on apache.org --20cf3054a6155e6e680494220852 Content-Type: text/plain; charset=UTF-8 Hm.. Reading: http://guide.couchdb.org/draft/security.html Suggestion is that you you can: curl -X PUT $HOST/_config/admins/doug -d '"secret"' But I get: 1> [info] [<0.1556.0>] 127.0.0.1 - - 'PUT' /_config/admins/doug 400 1> [debug] [<0.1556.0>] httpd 400 error response: {"error":"bad_request","reason":"invalid UTF-8 JSON"} On the other hand, I can do this: curl -X PUT $HOST/_config/admins/doug -d '"{'doug' : 'secret'}"' ...but then I get: 1> [info] [<0.2050.0>] 127.0.0.1 - - 'PUT' /_config/admins/doug 500 1> [debug] [<0.2050.0>] httpd 500 error response: {"error":"unknown_error","reason":"badarg"} So, question is, what's the right syntax here? Looking at the 'fix this' actions, I see: 1> [debug] [<0.2202.0>] 'PUT' /_config/admins/doug {1,1} Headers: [{'Accept',"application/json, text/javascript, */*"}, {'Accept-Encoding',"gzip, deflate"}, {'Accept-Language',"en-us"}, {'Connection',"keep-alive"}, {'Content-Length',"8"}, {'Content-Type',"application/json; charset=UTF-8"}, {'Host',"127.0.0.1:5984"}, {"Origin","http://127.0.0.1:5984"}, {'Referer',"http://127.0.0.1:5984/_utils/config.html"}, {'User-Agent',"Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_4; en-us) AppleWebKit/533.18.1 (KHTML, like Gecko)"}, {"X-Requested-With","XMLHttpRequest"}] 1> [debug] [<0.2202.0>] OAuth Params: [] 1> [info] [<0.2202.0>] 127.0.0.1 - - 'PUT' /_config/admins/doug 200 ...but I can't figure out how to see what actually got sent along with that request as content... ~ Doug. --20cf3054a6155e6e680494220852--