Re: [OAUTH-WG] User-agent flow and pre-registered redirect_uri

George Fletcher <gffletch@aol.com> Fri, 11 June 2010 20:02 UTC

Return-Path: <gffletch@aol.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 E8F1F28C0F8 for <oauth@core3.amsl.com>; Fri, 11 Jun 2010 13:02:13 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.298
X-Spam-Level:
X-Spam-Status: No, score=-1.298 tagged_above=-999 required=5 tests=[AWL=-1.300, BAYES_50=0.001, 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 ejPNTgigPAdx for <oauth@core3.amsl.com>; Fri, 11 Jun 2010 13:02:12 -0700 (PDT)
Received: from imr-mb02.mx.aol.com (imr-mb02.mx.aol.com [64.12.207.163]) by core3.amsl.com (Postfix) with ESMTP id 239963A699D for <oauth@ietf.org>; Fri, 11 Jun 2010 13:02:09 -0700 (PDT)
Received: from mtaout-ma02.r1000.mx.aol.com (mtaout-ma02.r1000.mx.aol.com [172.29.41.2]) by imr-mb02.mx.aol.com (8.14.1/8.14.1) with ESMTP id o5BK21es020994 for <oauth@ietf.org>; Fri, 11 Jun 2010 16:02:01 -0400
Received: from palantir.local (unknown [10.172.1.149]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mtaout-ma02.r1000.mx.aol.com (MUA/Third Party Client Interface) with ESMTPSA id CF152E00009C for <oauth@ietf.org>; Fri, 11 Jun 2010 16:01:59 -0400 (EDT)
Message-ID: <4C129636.8060004@aol.com>
Date: Fri, 11 Jun 2010 16:01:58 -0400
From: George Fletcher <gffletch@aol.com>
Organization: AOL LLC
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1.9) Gecko/20100317 Thunderbird/3.0.4
MIME-Version: 1.0
To: oauth@ietf.org
References: <AANLkTingSGlJNZ5e_stPd1qU5I4gfbh3rQhqYUmqXvdB@mail.gmail.com> <C833CEB4.6B81%cmortimore@salesforce.com> <AANLkTinVQEPBVzmiHEGgHhzaILL0nRSvZpjIlrVEJwTw@mail.gmail.com> <AANLkTil1j7vl8PU2tgCzlWY0U6KiWPmRKiVOxvsctB00@mail.gmail.com> <AANLkTimCL-O7RIsUlt_zGDfkEEYb9w4_sPh6zxCMBsf0@mail.gmail.com> <AANLkTin7B9pPgSu3cNlJGkp_gCed-5aPGRZalzXd2Wg8@mail.gmail.com> <4C124A70.2000002@aol.com> <1276268753.31840.50.camel@localhost.localdomain> <4C1257B5.9080706@comlounge.net> <AANLkTilcpAw7hZuQK43_ybS-wy3bQnPqMfRXOdqY4iYa@mail.gmail.com> <AANLkTimGnTj1HseMsPBaRXjBThM3uktqq0R6P30jsjaZ@mail.gmail.com> <AANLkTimyvpXmlOXRKSA4Oe0s3rqoiLQgtgvbRlvniEJ6@mail.gmail.com> <4C126367.40403@aol.com> <AANLkTimKEFRu-PboKcpXFlFN7Q_675ZjICBnK9IliUzs@mail.gmail.com> <4C126D63.9090903@aol.com> <AANLkTinryo8AMgqgQoPgn0cAxuYNXhHtBS--rx5A52Zb@mail.gmail.com> <4C12848E.8090105@aol.com> <AANLkTimIkVSldwpWtKgRjZushfH9_JzzzoJ7PIsp97ET@mail.gmail.com>
In-Reply-To: <AANLkTimIkVSldwpWtKgRjZushfH9_JzzzoJ7PIsp97ET@mail.gmail.com>
Content-Type: multipart/alternative; boundary="------------030901080908030500010500"
x-aol-global-disposition: G
X-AOL-SCOLL-SCORE: 0:2:406275808:93952408
X-AOL-SCOLL-URL_COUNT: 0
x-aol-sid: 3039ac1d29024c1296372a1b
X-AOL-IP: 10.172.1.149
Subject: Re: [OAUTH-WG] User-agent flow and pre-registered redirect_uri
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, 11 Jun 2010 20:02:14 -0000

On 6/11/10 3:15 PM, Marius Scurtescu wrote:
> On Fri, Jun 11, 2010 at 11:46 AM, George Fletcher<gffletch@aol.com>  wrote:
>    
>> On 6/11/10 2:09 PM, Marius Scurtescu wrote:
>>      
>>> On Fri, Jun 11, 2010 at 10:07 AM, George Fletcher<gffletch@aol.com>
>>>   wrote:
>>>
>>>        
>>>> Well... given this is a POST and structured data... it would be possible
>>>> for
>>>> the desktop app to post the raw icon data (though I suppose it could also
>>>> POST a URL to the web server of the company the produces the app). In
>>>> which
>>>> case your previous suggestion would work (parameters discovered via the
>>>> URL).
>>>>
>>>> I do believe the client_secret is valuable in this case because the AS is
>>>> returning both the client_id and the client_secret. This then becomes a
>>>> way
>>>> for provisioning a unique client_id and client_secret to every instance
>>>> of
>>>> the app. A lot more for the AS to keep track of, but also makes it more
>>>> difficult for an attacker to compromise a client. The attacker could
>>>> impersonate the POST'd client description data (just like user-agent
>>>> strings
>>>> can be impersonated), but then the attacker just has a client_id and
>>>> client_secret for it's instance.
>>>>
>>>> This should force the attacker to get explicit user consent from the user
>>>> to
>>>> authorize that unique client_id. I wouldn't recommend for the AS to track
>>>> authorization against the POST'd client description but rather the
>>>> client_id.
>>>>
>>>>          
>>> An attacker can also dynamically register a very similar client
>>> name/description and trick the user.
>>>
>>>        
>> True... but the user will see another consent form. This might be a minor
>> hurdle but at least it's not totally seamless. I think that is an advantage.
>>      
> Why would the user see another consent form? Were you thinking
> auto-approvals? For desktop apps auto-approvals don't make much sense
> and authz servers should probably never do that.
>    
This based on my assumptions about authorization approvals. In my 
experience, the authorization is based off the client_id (or it's 
equivalent... developer key, api key, etc). So if a user has already 
given consent to that client_id, why would the authorization service ask 
the user for consent again if presented with the same client_id? To do 
this, the authorization would have to consider some additional 
parameters beside client_id when determining whether to ask the user to 
consent to the authorization or not. I suppose if the authorization 
server required user consent every time the client requested 
authorization ( 2.5.1. Client Requests Authorization), then I agree that 
having a unique client_id doesn't provide much value.

>> So maybe the solution is that if the authorization server doesn't think the
>> client_secret is useful, it doesn't return it. Or it always returns it and
>> the client can throw it away as it knows it won't use it. However, it seems
>> like the rest of the registration flow still holds.
>>      
> Without client_secret I still don't see the point. Registration then
> boils down to self asserted name, which can also be achieved with the
> client_name paramter, no?
>    
Well.. there might be a slight difference. By having a specific endpoint 
for registering a client, the authorization server can chose to give out 
a unique client_id every time the API is called (or based on some other 
rules). This prevents one level of "impersonation". It also keeps the 
existing model the same (clients are represented uniquely by a 
client_id). Some registered out-of-band, some registered dynamically.

As far as how to represent the client, I think that more than just the 
client_name (as in a string) is valuable. However, this can be 
accomplished via client_name being a URL with discoverable meta-data or 
a POST'd data structure.

Thanks,
George