Return-Path: Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: (qmail 78630 invoked from network); 27 Jul 2009 22:08:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 27 Jul 2009 22:08:10 -0000 Received: (qmail 83585 invoked by uid 500); 27 Jul 2009 22:09:16 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 83497 invoked by uid 500); 27 Jul 2009 22:09:15 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 83488 invoked by uid 500); 27 Jul 2009 22:09:15 -0000 Delivered-To: apmail-incubator-couchdb-commits@incubator.apache.org Received: (qmail 83485 invoked by uid 99); 27 Jul 2009 22:09:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 27 Jul 2009 22:09:15 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.130] (HELO eos.apache.org) (140.211.11.130) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 27 Jul 2009 22:09:07 +0000 Received: from eos.apache.org (localhost [127.0.0.1]) by eos.apache.org (Postfix) with ESMTP id EBE04118BA for ; Mon, 27 Jul 2009 22:08:46 +0000 (GMT) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Apache Wiki To: couchdb-commits@incubator.apache.org Date: Mon, 27 Jul 2009 22:08:46 -0000 Message-ID: <20090727220846.26125.64839@eos.apache.org> Subject: [Couchdb Wiki] Update of "Authentication and Authorization" by CurtArnold X-Virus-Checked: Checked by ClamAV on apache.org Dear Wiki user, You have subscribed to a wiki page or wiki category on "Couchdb Wiki" for change notification. The following page has been changed by CurtArnold: http://wiki.apache.org/couchdb/Authentication_and_Authorization ------------------------------------------------------------------------------ }). }}} + == Authentication handlers == + + === couch_http::default_authentication_handler === + + If the http request contains basic authentication, the user name and password are checked + against a configured user list. If the user is recognized as an administrator, the user name and + _admin role are added to the user context, otherwise, an exception is thrown. + If basic authentication is not present and there are admins defined in the user list, + an empty context is returned. If basic authentication is not present and there are no admins + defined, then the _admin role is added to the context. + + + === couch_http::null_authentication_handler === + + Any request is granted the _admin role. + + === couch_http::special_test_authentication_handler === + + If the WWW-Authentication header has a value like "X-Couch-Test-Auth username:password", + the user name and password are checked against a hard-coded list of username/password + combinations. If the request matches, the user name (but not the _admin role) is added, + otherwise an exception is thrown. If the WWW-Authentication header is not present + or does not match the pattern, the _admin role is added. + + === couch_httpd_oauth::oauth_authentication_handler === + + [http://issues.apache.org/jira/browse/COUCHDB-420 COUCHDB-420] implements an + [http://oauth.net/ OAuth] authentication handler. The patch also changes + couch_http to accept a list of authentication handlers instead of a single + authentication handler. + == Authorization use cases ==