Re: [OAUTH-WG] Signature crypto

Eran Hammer-Lahav <eran@hueniverse.com> Fri, 04 December 2009 20:36 UTC

Return-Path: <eran@hueniverse.com>
X-Original-To: oauth@core3.amsl.com
Delivered-To: oauth@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id C25E03A68FD for <oauth@core3.amsl.com>; Fri, 4 Dec 2009 12:36:36 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.953
X-Spam-Level:
X-Spam-Status: No, score=-2.953 tagged_above=-999 required=5 tests=[AWL=-0.355, BAYES_00=-2.599, HTML_MESSAGE=0.001]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7tzQwZ2SuFBA for <oauth@core3.amsl.com>; Fri, 4 Dec 2009 12:36:30 -0800 (PST)
Received: from p3plex1out02.prod.phx3.secureserver.net (p3plex1out02.prod.phx3.secureserver.net [72.167.180.18]) by core3.amsl.com (Postfix) with SMTP id E45CB3A6910 for <oauth@ietf.org>; Fri, 4 Dec 2009 12:36:29 -0800 (PST)
Received: (qmail 12615 invoked from network); 4 Dec 2009 20:36:21 -0000
Received: from unknown (HELO smtp.ex1.secureserver.net) (72.167.180.19) by p3plex1out02.prod.phx3.secureserver.net with SMTP; 4 Dec 2009 20:36:21 -0000
Received: from P3PW5EX1MB01.EX1.SECURESERVER.NET ([10.6.135.19]) by P3PW5EX1HT001.EX1.SECURESERVER.NET ([72.167.180.19]) with mapi; Fri, 4 Dec 2009 13:36:21 -0700
From: Eran Hammer-Lahav <eran@hueniverse.com>
To: Eran Hammer-Lahav <eran@hueniverse.com>, "OAuth WG (oauth@ietf.org)" <oauth@ietf.org>
Date: Fri, 04 Dec 2009 13:36:38 -0700
Thread-Topic: [OAUTH-WG] Signature crypto
Thread-Index: Acp1GnWoZAY5dSS+QcK0eFBSsffPuwAA/MdQAAC8B7A=
Message-ID: <90C41DD21FB7C64BB94121FBBC2E72343785293747@P3PW5EX1MB01.EX1.SECURESERVER.NET>
References: <90C41DD21FB7C64BB94121FBBC2E72343785183009@P3PW5EX1MB01.EX1.SECURESERVER.NET> <f98165700912041023y3207d801r42f01c7a0c4352bb@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E7234378529368A@P3PW5EX1MB01.EX1.SECURESERVER.NET> <daf5b9570912041037t199cc9d3rbd4d31d327f8988b@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E7234378529369B@P3PW5EX1MB01.EX1.SECURESERVER.NET> <f98165700912041048s7f1f53bs27ec2b78f7f44c8b@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E723437852936BC@P3PW5EX1MB01.EX1.SECURESERVER.NET> <daf5b9570912041112h71c0644dm8c908478dbff2e9a@mail.gmail.com> <f98165700912041120k2b13eed2l4b51f6b22e35824e@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E723437852936D7@P3PW5EX1MB01.EX1.SECURESERVER.NET> <f98165700912041146w2d543b25l9b1e7ec8df0ef8a0@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E72343785293745@P3PW5EX1MB01.EX1.SECURESERVER.NET>
In-Reply-To: <90C41DD21FB7C64BB94121FBBC2E72343785293745@P3PW5EX1MB01.EX1.SECURESERVER.NET>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
acceptlanguage: en-US
Content-Type: multipart/alternative; boundary="_000_90C41DD21FB7C64BB94121FBBC2E72343785293747P3PW5EX1MB01E_"
MIME-Version: 1.0
Subject: Re: [OAUTH-WG] Signature crypto
X-BeenThere: oauth@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: OAUTH WG <oauth.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/oauth>, <mailto:oauth-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/oauth>
List-Post: <mailto:oauth@ietf.org>
List-Help: <mailto:oauth-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/oauth>, <mailto:oauth-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 04 Dec 2009 20:36:36 -0000

And if it is not clear, this is very different from 1.0 in which the signature method includes what is being signed as well as how to normalize the output into the authenticated request. This separates the how to sign with what to sign and gives each a name.

EHL

From: oauth-bounces@ietf.org [mailto:oauth-bounces@ietf.org] On Behalf Of Eran Hammer-Lahav
Sent: Friday, December 04, 2009 12:35 PM
To: OAuth WG (oauth@ietf.org)
Subject: Re: [OAUTH-WG] Signature crypto

We have been to some extent talking part each other. Breno and I spend some time talking about this off line and reached a better understanding of our positions.

We have been approaching this from the wrong direction.

The server should not be broadcasting what types of algorithms it supports. Instead it should be listing what kind of *tokens* it supports. Since a token secret issued for use with HMAC-SHA1 should/may be different from that used with HMAC-SHA512, it is the token class that determines what it can be used with.

The server should indicate the kinds of tokens supported for a given resource/realm. When obtaining such tokens, the client will be provided with a new attribute indicating the token type (which will dictate how it should use it to sign/etc. the canonicalized request.).

The server should indicate in the WWW-Authenticate header which canonicalizations it supports (with bearer token being a special case).

The authentication scheme should specify how to take the raw signature and encode it into the Authentication header.

This means *are* going to pick a few token types to standardize which will include the crypto used, and allow extensions by publishing an RFC + registration.

EHL




From: Breno [mailto:breno.demedeiros@gmail.com]
Sent: Friday, December 04, 2009 11:46 AM
To: Eran Hammer-Lahav
Cc: Brian Eaton; OAuth WG (oauth@ietf.org)
Subject: Re: [OAUTH-WG] Signature crypto

I am not sure I buy this. For instance, RSA-SHA1 is _not_ a signature scheme, PKCS#11 does establish a signature scheme based on RSA + SHA-1.

So to delve beyond the level of abstraction of 'authentication mechanism name' you need to point to a separate spec for both signing and verification.

I am not sure how much one needs to do beyond defining the byte representation of what needs to be signed.

Some MACs require random pads in addition to keys. Those won't fit into this abstraction but I don't think we need absolute generality here.
On Fri, Dec 4, 2009 at 11:25 AM, Eran Hammer-Lahav <eran@hueniverse.com<mailto:eran@hueniverse.com>> wrote:
Point where?

I didn't mean new spec for the algorithm, just for how it is used with the OAuth authentication scheme.

EHL

From: Breno [mailto:breno.demedeiros@gmail.com<mailto:breno.demedeiros@gmail.com>]
Sent: Friday, December 04, 2009 11:20 AM
To: Brian Eaton
Cc: Eran Hammer-Lahav; OAuth WG (oauth@ietf.org<mailto:oauth@ietf.org>)

Subject: Re: [OAUTH-WG] Signature crypto

There is no need to publish a new spec for a new MAC algorithm. MAC algorithms typically go through certification (e.g., NIST) and have detailed specs, including test vectors for interoperability.

For OAuth, if you want to explicitly support a new MAC algorithm you will not need to change the transport and you just have to point to the particular spec that defines the MAC algorithm.
On Fri, Dec 4, 2009 at 11:12 AM, Brian Eaton <beaton@google.com<mailto:beaton@google.com>> wrote:
On Fri, Dec 4, 2009 at 11:10 AM, Eran Hammer-Lahav <eran@hueniverse.com<mailto:eran@hueniverse.com>> wrote:
> I am trying to avoid the need to publish a specification every time you want
> to add a new MAC-based algorithm.
People are going to end up needing to write new code every time they
want to add a new MAC-based algorithm.
Cheers,
Brian



--
Breno de Medeiros



--
Breno de Medeiros