Re: [OAUTH-WG] Comments on draft-richer-oauth-introspection-04

Thomas Broyer <t.broyer@gmail.com> Thu, 24 October 2013 00:27 UTC

Return-Path: <t.broyer@gmail.com>
X-Original-To: oauth@ietfa.amsl.com
Delivered-To: oauth@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EAE1111E829A for <oauth@ietfa.amsl.com>; Wed, 23 Oct 2013 17:27:56 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.599
X-Spam-Level:
X-Spam-Status: No, score=-2.599 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, HTML_MESSAGE=0.001, NO_RELAYS=-0.001]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id y4p86sd8QaKF for <oauth@ietfa.amsl.com>; Wed, 23 Oct 2013 17:27:56 -0700 (PDT)
Received: from mail-ve0-x230.google.com (mail-ve0-x230.google.com [IPv6:2607:f8b0:400c:c01::230]) by ietfa.amsl.com (Postfix) with ESMTP id 32A8211E82A4 for <oauth@ietf.org>; Wed, 23 Oct 2013 17:27:53 -0700 (PDT)
Received: by mail-ve0-f176.google.com with SMTP id jx11so873207veb.21 for <oauth@ietf.org>; Wed, 23 Oct 2013 17:27:53 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=esoUN++Cwfs6bMZyanjBGRaEOwzTQ8jnQQVGejfxdnY=; b=IXc7f4bbqhS2PCfJNPtS7nE46603NrZgLtwb62uzgUCH98unoCTaIkvm0PlY+cho3P UcifCPEfV9ebgPpGEUO+bjoIiyNbWGdZRFVNYw/+phrKVCPVfjSB3OiYuJsJYzmJp1ev ZtxL6sBLk2mPPRTAhRlnDiv8XpjAFcaipdcZYHar5jLo5yYC/jTYootBgP9HKdCQAKZG JA69087RNSqObkyo9QKypujRN1vEtqcdBg6GciSbpuNWZJKyWs7wL4JGj4fal6Hcnpwb GJ4esJjYsY2JGkEmxwMBiYsIcy6lty4tI/9+7PqGuB0Ol6SdTHmsZibf9vj9zd/N6VpN DN7Q==
X-Received: by 10.58.136.231 with SMTP id qd7mr2939026veb.1.1382574473297; Wed, 23 Oct 2013 17:27:53 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.220.219.132 with HTTP; Wed, 23 Oct 2013 17:27:33 -0700 (PDT)
In-Reply-To: <63692DF5-4616-4F53-B12E-518397CFEFB3@mitre.org>
References: <CAEayHENijdeTVu9-OxsnrJEh0JQBrvQo0eKWSjFvXSLqwzVRWg@mail.gmail.com> <63692DF5-4616-4F53-B12E-518397CFEFB3@mitre.org>
From: Thomas Broyer <t.broyer@gmail.com>
Date: Thu, 24 Oct 2013 02:27:33 +0200
Message-ID: <CAEayHEMZdOY5G=A5nc_pA14gUcyNpbbeb-pVpo7Cf_yB70Mjjw@mail.gmail.com>
To: "Richer, Justin P." <jricher@mitre.org>
Content-Type: multipart/alternative; boundary="047d7b5d45d05b47c504e971b477"
Cc: "<oauth@ietf.org>" <oauth@ietf.org>
Subject: Re: [OAUTH-WG] Comments on draft-richer-oauth-introspection-04
X-BeenThere: oauth@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: OAUTH WG <oauth.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/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: Thu, 24 Oct 2013 00:27:57 -0000

On Wed, Oct 23, 2013 at 9:22 PM, Richer, Justin P. <jricher@mitre.org>wrote:

>  Hi Thomas,
>
>  You're right in that the introspection process is about getting meta
> data about a particular token by making an authenticated call. It does
> reveal a lot of information about the token -- because that's exactly the
> point of the protocol. :)
>
>  If the PR is compromised, then the attacker would be able to do anything
> the PR can do, including reusing any tokens handed to the PR (assuming
> they're bearer tokens).
>

Yes, this is the problem with bearer tokens. Is there any spec for 'proof
tokens' besides http-mac?
As a mean of mitigating the issue, I was thinking about delivering a
refresh_token and asking Clients to generate (ask the AS) different access
tokens for each PR (or "resource set"). That would of course solve the
issue with introspection giving too much information (to my taste), but
puts burden on Client implementors, with no guarantee that they'll actually
do it. AFAICT, only a 'proof token' would really solve the issue; it's in
our backlog.


> This is true without doing introspection at all, since you can just steal
> and start broadcasting the token.
>

But then the AS could revoke the access token when it detects a high rate
of validation/introspection requests from many different PRs, particularly
many such requests in error!
Giving the compromised victim the list of scopes for the token would
severely limits the number of errors and it would be much harder to detect
such compromised entities.

Also, if the PR is compromised, all the data protected at that PR is also
> compromised, so you've got other problems too.
>

That's a problem between the PR and the ROs then, unrelated to the AS or
even Clients.
It becomes a problem with the whole system when compromising one entity
(other than the AS) gives access to personal data in others.


>  The "resource_id" parameter is meant to be a service-specific hint that
> the PR can hand to the AS to give context to the transaction. You could
> easily use this field to pass along the list of scopes that you mention
> below.
>

I had just skimmed through resource-reg and didn't remember the "resource
set" concept. Now that I re-read it, I better understand what that
resource_id can be.


> You can have your AS return no information other than the "valid" field in
> the response and leave out the scopes, subject, client id, and everything
> else. All those fields are optional. However, in practice we've found it
> very helpful to reveal to the PR which scopes and audiences that a token
> was issued for so that the PR can use that information to make
> authorization decisions.
>

But aren't authorization decisions the responsibility of the AS?
If the PR sent the scopes (or resource_id, but that would closely couple
the protocol with resource-reg, which I don't think is desirable) to the
AS, then the PR could authorize access based only on a yes/no response (and
the "no" response would give information about the "why", to be sent
directly to the Client)


> But if all you're after is answering the question "is this token valid"
> and you don't want any other information, your AS is fully allowed to do
> answer just that question.
>

As I said, I do need "more information", or rather, a more "contextual"
information.

I think I'll just go with my custom protocol for now. Thanks for your
answer.