Re: [OAUTH-WG] in-app logout?

"Manger, James H" <James.H.Manger@team.telstra.com> Tue, 18 May 2010 23:56 UTC

Return-Path: <James.H.Manger@team.telstra.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 A119B3A6A55 for <oauth@core3.amsl.com>; Tue, 18 May 2010 16:56:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 1.834
X-Spam-Level: *
X-Spam-Status: No, score=1.834 tagged_above=-999 required=5 tests=[AWL=-0.465, BAYES_50=0.001, HELO_EQ_AU=0.377, HOST_EQ_AU=0.327, J_CHICKENPOX_66=0.6, RELAY_IS_203=0.994]
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 GPvLYHGfwBOE for <oauth@core3.amsl.com>; Tue, 18 May 2010 16:56:25 -0700 (PDT)
Received: from ipxavo.tcif.telstra.com.au (ipxavo.tcif.telstra.com.au [203.35.135.200]) by core3.amsl.com (Postfix) with ESMTP id 23FC83A6765 for <oauth@ietf.org>; Tue, 18 May 2010 16:56:24 -0700 (PDT)
X-IronPort-AV: E=Sophos;i="4.53,258,1272808800"; d="scan'208";a="2880583"
Received: from unknown (HELO ipccvi.tcif.telstra.com.au) ([10.97.217.208]) by ipoavi.tcif.telstra.com.au with ESMTP; 19 May 2010 09:56:16 +1000
X-IronPort-AV: E=McAfee;i="5400,1158,5986"; a="2095640"
Received: from wsmsg3702.srv.dir.telstra.com ([172.49.40.170]) by ipccvi.tcif.telstra.com.au with ESMTP; 19 May 2010 09:56:16 +1000
Received: from WSMSG3153V.srv.dir.telstra.com ([172.49.40.159]) by WSMSG3702.srv.dir.telstra.com ([172.49.40.170]) with mapi; Wed, 19 May 2010 09:56:16 +1000
From: "Manger, James H" <James.H.Manger@team.telstra.com>
To: Dick Hardt <dick.hardt@gmail.com>
Date: Wed, 19 May 2010 09:56:14 +1000
Thread-Topic: [OAUTH-WG] in-app logout?
Thread-Index: Acr1V6V5RHG4XS9qSOu+PuQk5E2IDQBiV+Tw
Message-ID: <255B9BB34FB7D647A506DC292726F6E11263720D85@WSMSG3153V.srv.dir.telstra.com>
References: <4BEBDCFB.7090503@lodderstedt.net> <255B9BB34FB7D647A506DC292726F6E11263465727@WSMSG3153V.srv.dir.telstra.com> <AANLkTikxD3jraqvG2IFmaSme0f1Q7NGPuQ3llqX3Ds5W@mail.gmail.com> <255B9BB34FB7D647A506DC292726F6E112634F5EA3@WSMSG3153V.srv.dir.telstra.com> <7934BAC5-7FA8-48E7-82A5-A4A17DE9146E@gmail.com>
In-Reply-To: <7934BAC5-7FA8-48E7-82A5-A4A17DE9146E@gmail.com>
Accept-Language: en-US, en-AU
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
acceptlanguage: en-US, en-AU
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
Cc: "OAuth WG (oauth@ietf.org)" <oauth@ietf.org>
Subject: Re: [OAUTH-WG] in-app logout?
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: Tue, 18 May 2010 23:56:26 -0000

Dick,

I may have misinterpreted you design objective of "allowing existing systems to use existing tokens" as meaning: the refresh_token field shouldn't be defined as a URI as some existing tokens are too big to fit in URIs.

If the size of existing tokens is an issue then the user-agent flow will not work -- since it returns an access_token (and, optionally, a refresh_token as well) in a URI fragment.

An existing token always needs to be extracted from a request: typically from a FORM-encoded string of parameters. Defining refresh_token as a URI doesn't really change this: an existing token can still be extracted from a query parameter in such a URI. I believe this still meets a design objective of allowing existing systems to use existing tokens.


So I suggest renaming refresh_token to, say, token_uri, and defining it to be a URI.


P.S. An authz service could even choose the following so a refresh request looks much like the current draft if it really needed that.
  "token_uri": "/token?refresh_token=8xLOxBtZp8"


-- 
James Manger


-----Original Message-----
From: Dick Hardt [mailto:dick.hardt@gmail.com] 
Sent: Monday, 17 May 2010 10:27 AM
To: Manger, James H
Cc: OAuth WG (oauth@ietf.org)
Subject: Re: [OAUTH-WG] in-app logout?


On 2010-05-16, at 5:20 PM, Manger, James H wrote:

> Dick,
> 
>> James: An important capability of the refresh token is that it *can* be a self contained token in that is not an id, but a signed token that can be examined and acted upon on presentation.
> 
> Defining refresh_token as a URI does not prevent it being a self-contained signed token.
> 
> The only limitation implied is a URI size limit. A few KB, however, is not that onerous a limit -- it is sufficient to hold a 4096-bit RSA signature with a couple of KB over for permissions etc.).

Agreed, a token could be a self contained token. A design objective was allowing existing systems to use existing tokens.

-- Dick


-----Original Message-----
From: oauth-bounces@ietf.org [mailto:oauth-bounces@ietf.org] On Behalf Of Manger, James H
Sent: Friday, 14 May 2010 12:10 AM
To: Torsten Lodderstedt; OAuth WG (oauth@ietf.org)
Subject: Re: [OAUTH-WG] in-app logout?

Torsten,

> What about refresh token revocation/deletion?

HTTP already has a method to do this: DELETE
It just needs each token to have a URI.

Tokens (almost) already have URIs -- its just not immediately obvious because the URI has to be built from a common token endpoint and a refresh_token.

I think it would improve the spec if refresh_token was renamed to, say, token_id; and its value defined as a URI (which can be a relative URI so the string may not need to change at all).

To refresh a token you POST to the token's URI.
To delete a token you send a DELETE request to the token's URI.

It doesn't cause major changes, but there are some benefits.
It is a more web-style design.
It leaves only 1 type of token in the spec -- an access token -- which simplifies the text and aids understanding.
There are no arguments about length, allowed chars etc because it is a URI -- a well-known type, often with native support.
Its obvious how to delete the token as there is a standard HTTP method DELETE to apply to the token URI.

If a particular service supported an additional way to delete items in its API (eg POST with a method=delete query parameter) that could apply to the OAuth part as well.

--
James Manger