Re: [OAUTH-WG] Clarification: authorization server matching of redirect URI

Eran Hammer-Lahav <eran@hueniverse.com> Mon, 19 April 2010 18:20 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 242BC3A689A for <oauth@core3.amsl.com>; Mon, 19 Apr 2010 11:20:20 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.468
X-Spam-Level:
X-Spam-Status: No, score=-2.468 tagged_above=-999 required=5 tests=[AWL=0.131, 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 N+PGkJgoUwe6 for <oauth@core3.amsl.com>; Mon, 19 Apr 2010 11:20:18 -0700 (PDT)
Received: from p3plex1out01.prod.phx3.secureserver.net (p3plex1out01.prod.phx3.secureserver.net [72.167.180.17]) by core3.amsl.com (Postfix) with SMTP id 84B8F3A6836 for <oauth@ietf.org>; Mon, 19 Apr 2010 11:20:15 -0700 (PDT)
Received: (qmail 19116 invoked from network); 19 Apr 2010 18:20:06 -0000
Received: from unknown (HELO smtp.ex1.secureserver.net) (72.167.180.19) by p3plex1out01.prod.phx3.secureserver.net with SMTP; 19 Apr 2010 18:20:06 -0000
Received: from P3PW5EX1MB01.EX1.SECURESERVER.NET ([10.6.135.20]) by P3PW5EX1HT001.EX1.SECURESERVER.NET ([72.167.180.19]) with mapi; Mon, 19 Apr 2010 11:19:51 -0700
From: Eran Hammer-Lahav <eran@hueniverse.com>
To: Marius Scurtescu <mscurtescu@google.com>
Date: Mon, 19 Apr 2010 11:19:54 -0700
Thread-Topic: [OAUTH-WG] Clarification: authorization server matching of redirect URI
Thread-Index: Acrf6CtjGaVFyvGlRhacun6PivpBZQABFsbw
Message-ID: <90C41DD21FB7C64BB94121FBBC2E723438E5C7F188@P3PW5EX1MB01.EX1.SECURESERVER.NET>
References: <2997F829-4755-44A8-ADD5-643BCE25AA61@gmail.com> <90C41DD21FB7C64BB94121FBBC2E723438E30A379C@P3PW5EX1MB01.EX1.SECURESERVER.NET> <65D588CD-A374-4F6B-8749-199C5DF83300@gmail.com> <x2kdaf5b9571004190836l2595e181obdb977045e11c49e@mail.gmail.com> <90C41DD21FB7C64BB94121FBBC2E723438E5C7F059@P3PW5EX1MB01.EX1.SECURESERVER.NET> <i2w74caaad21004191045v4c55ddc7p61d8f250210afc3b@mail.gmail.com>
In-Reply-To: <i2w74caaad21004191045v4c55ddc7p61d8f250210afc3b@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
acceptlanguage: en-US
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
Cc: OAuth WG <oauth@ietf.org>
Subject: Re: [OAUTH-WG] Clarification: authorization server matching of 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: Mon, 19 Apr 2010 18:20:20 -0000

I am not sure we can specify how callbacks are registered which is where your syntax resides. The whole registration process is out of scope. The server has *something* and needs to match the callback in the request to it.

My proposal is to provide a narrow facility with the client state parameter which makes this simple, but somewhat limited, and allow servers to support a more robust system using any client provided callback parameter.

My problem is that I don't know where to put these rules because we don't have a section dealing with callback registration.

EHL

> -----Original Message-----
> From: Marius Scurtescu [mailto:mscurtescu@google.com]
> Sent: Monday, April 19, 2010 10:46 AM
> To: Eran Hammer-Lahav
> Cc: Brian Eaton; Dick Hardt; OAuth WG
> Subject: Re: [OAUTH-WG] Clarification: authorization server matching of
> redirect URI
> 
> On Mon, Apr 19, 2010 at 8:39 AM, Eran Hammer-Lahav
> <eran@hueniverse.com> wrote:
> >
> >
> >> -----Original Message-----
> >> From: Brian Eaton [mailto:beaton@google.com]
> >> Sent: Monday, April 19, 2010 8:37 AM
> >> To: Dick Hardt
> >> Cc: Eran Hammer-Lahav; OAuth WG
> >> Subject: Re: [OAUTH-WG] Clarification: authorization server matching
> >> of redirect URI
> >>
> >> On Sun, Apr 18, 2010 at 10:35 PM, Dick Hardt <dick.hardt@gmail.com>
> wrote:
> >> > The spec should describe how the redirect URI is verified to what
> >> > is
> >> registered. I can enumerate the options for discussion adding in the
> >> state parameter as an option.
> >>
> >> Note that there are two spots where the AS does some URI matching.
> >>
> >> The first is before redirecting the user to the callback URI.  This
> >> seems doomed to being service provider specific, unfortunately.
> >
> > I agree. If someone wants to suggest some security consideration text that
> would be good.
> 
> If this is authz server specific I can see the following problem:
> - authz server 1 allows regular expressions in registered callback URLs
> - client integrates with authz server 1 and designs its own implementation
> based on these callback URLs, uses load balancing on different hosts and
> passes state through query parameters
> - authz server 2 comes along and it requires strict matching on callbacks
> - client wants to integrate with authz server 2 as well, but will have to rewrite
> everything because the load balancing and state infrastructure will not work
> 
> In order to support interop I think it would be useful to specify how callbacks
> are matched.
> 
> Proposal:
> - path and query string are strictly matched (the spec has a state parameter)
> - host names can contain a wild card (to allow for load balancing)
> - port and scheme strictly matched
> 
> For example:
> - registered callback: https://*.example.com/client?controller=oauth2
> - matching callbacks:
>   https://example.com/client?controller=oauth2
>   https://sv1.example.com/client?controller=oauth2
>   https://sv2.n1.example.com/client?controller=oauth2
> - not matching:
>   https://example.net/client?controller=oauth2
>   https://example.com/client?controller=oauth2&user=x
>   http://example.com/client?controller=oauth2
>   https://example.com:8080/client?controller=oauth2
> 
> 
> Marius