Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0D76DDAD1 for ; Thu, 8 Nov 2012 21:28:41 +0000 (UTC) Received: (qmail 12250 invoked by uid 500); 8 Nov 2012 21:28:39 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 12208 invoked by uid 500); 8 Nov 2012 21:28:39 -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 12200 invoked by uid 99); 8 Nov 2012 21:28:39 -0000 Received: from minotaur.apache.org (HELO minotaur.apache.org) (140.211.11.9) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Nov 2012 21:28:39 +0000 Received: from localhost (HELO mail-vb0-f52.google.com) (127.0.0.1) (smtp-auth username rnewson, mechanism plain) by minotaur.apache.org (qpsmtpd/0.29) with ESMTP; Thu, 08 Nov 2012 21:28:38 +0000 Received: by mail-vb0-f52.google.com with SMTP id k17so3074082vbj.11 for ; Thu, 08 Nov 2012 13:28:37 -0800 (PST) MIME-Version: 1.0 Received: by 10.58.249.201 with SMTP id yw9mr3416402vec.10.1352410117885; Thu, 08 Nov 2012 13:28:37 -0800 (PST) Received: by 10.52.69.79 with HTTP; Thu, 8 Nov 2012 13:28:37 -0800 (PST) In-Reply-To: References: <20121011164501.5b4b2c54@eee-az> Date: Thu, 8 Nov 2012 21:28:37 +0000 Message-ID: Subject: Re: can replicator work with cookies somehow? From: Robert Newson To: "user@couchdb.apache.org" Content-Type: multipart/alternative; boundary=047d7bacc07eaacda004ce0284d1 --047d7bacc07eaacda004ce0284d1 Content-Type: text/plain; charset=ISO-8859-1 You can use cookie auth for the replication using this little known API variant; "target":{"url" : "http://host:port/db", "headers":{"cookie":"AuthSession=foo"}} B. On 8 November 2012 20:22, bsquared wrote: > On 10/11/2012 06:45 AM, svilen wrote: > >> i need to start replications on behalf of a user. >> >> i see there's basic http user/psw authtenticaion, and some form of >> oauth. >> basic http means i have to keep usr/psw around, and use them when i need >> replication. >> but i'd like to avoid storing that usr/psw. >> >> as i see there are cookies (via /_session), can replicator work with >> cookies somehow? >> >> or if not, how can i use oauth given there's no 3rd party involved >> (facebook/twitter/..)? e.g. some kind of degenerate made-up-myself? >> >> ciao >> svil >> >> I believe the credentials have to be supplied in the URL ie. > https://user:password@couchdb_**instance[:port]. > > There is a gist on github that covers the replicator db. > > gist.github.com/832610 > > > -- > Regards, > Brian > > --047d7bacc07eaacda004ce0284d1--