Re: [OAUTH-WG] 'Scope' parameter proposal

Dick Hardt <dick.hardt@gmail.com> Tue, 20 April 2010 03:07 UTC

Return-Path: <dick.hardt@gmail.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 DB7793A69B7 for <oauth@core3.amsl.com>; Mon, 19 Apr 2010 20:07:01 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.42
X-Spam-Level:
X-Spam-Status: No, score=-2.42 tagged_above=-999 required=5 tests=[AWL=0.179, BAYES_00=-2.599]
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 5YVEphP8zeAt for <oauth@core3.amsl.com>; Mon, 19 Apr 2010 20:07:01 -0700 (PDT)
Received: from mail-vw0-f44.google.com (mail-vw0-f44.google.com [209.85.212.44]) by core3.amsl.com (Postfix) with ESMTP id 6DEC23A69B5 for <oauth@ietf.org>; Mon, 19 Apr 2010 20:07:00 -0700 (PDT)
Received: by vws12 with SMTP id 12so341126vws.31 for <oauth@ietf.org>; Mon, 19 Apr 2010 20:06:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=MPEIaXuJQF03KoHLaXhJKZBH3CiCx1Y7/NrL4NBAWYs=; b=BAL/G0Qo6JFX8lRBc40BtzpftIIQCOYbNA/7y+FlNfb1NBTJWHvo4wbTa0EYe6Q53v j7KDMVSfYfiMKxEk+bOVSxehj/fRJZAePOcv2OxNVNbtnE+xvfI2HNBRBU5pqhKuqxsC W8ceTLrwDqa3jLwubpI6o0Y/85fNkEuTVmfjE=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=EAoC6l9OmyVjc9eX9H/jkecTBs9p58EUoI23ASuB1zeGdQr+37GNdCvqc2IKFXkSW1 bpUqQlM8j0UKkhBFy0GUs6FOdP1slkRQ9+XcJ6UXPh7X2XQyxLkAQ0rHw3bnQv/xW5Wy Gpvm9sV64q4dBGXgFK334upB64/j9bh5adGiU=
Received: by 10.220.107.4 with SMTP id z4mr4227037vco.147.1271732804155; Mon, 19 Apr 2010 20:06:44 -0700 (PDT)
Received: from [10.0.1.4] (c-67-180-195-167.hsd1.ca.comcast.net [67.180.195.167]) by mx.google.com with ESMTPS id z17sm21552516vco.5.2010.04.19.20.06.42 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 19 Apr 2010 20:06:43 -0700 (PDT)
Mime-Version: 1.0 (Apple Message framework v1078)
Content-Type: text/plain; charset="us-ascii"
From: Dick Hardt <dick.hardt@gmail.com>
In-Reply-To: <C7F1D1FC.32809%eran@hueniverse.com>
Date: Mon, 19 Apr 2010 20:06:40 -0700
Content-Transfer-Encoding: quoted-printable
Message-Id: <620F3756-E159-4EF3-99DC-6D74CC869739@gmail.com>
References: <C7F1D1FC.32809%eran@hueniverse.com>
To: Eran Hammer-Lahav <eran@hueniverse.com>
X-Mailer: Apple Mail (2.1078)
Cc: OAuth WG <oauth@ietf.org>
Subject: Re: [OAUTH-WG] 'Scope' parameter proposal
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, 20 Apr 2010 03:07:02 -0000

On 2010-04-19, at 9:25 AM, Eran Hammer-Lahav wrote:
> 2. Server requires authentication
> 
>    HTTP/1.1 401 Unauthorized
>    WWW-Authenticate: Token realm='Example', scope='x2'

Can more than one scope be returned? Is it a comma delimited list?

I wonder how much value this will provide. (I like the idea, but teasing out the implications.)

Imagine we have a resource that can have READ or  WRITE access granted.

An unauthenticated GET on the resource could return the scope URI needed for READ, an unauthenticated PUT on the resource could return the scope URI for WRITE. What if you want to both do READs and WRITEs? There may be another scope that is READ/WRITE. READ and WRITE are pretty common capabilities, but one can imagine much more complex capabilities at resources.

The exact semantics to the resource are likely going to very contextual.

Given that, returning a single scope value if that is all that makes sense to the resource will likely address many use cases.

(+1 to Eran's proposal given all the other factors)

-- Dick