<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">That is the correct setup — B is the resource server. We re-used the “client” system in MITREid because it already had all of the attributes that we cared about for resource servers and it didn’t make sense to duplicate it.&nbsp;<div class=""><br class=""></div><div class="">The resource server checks the access token when the client presents the access token to the resource server. The resource server simply picks the token up off of the incoming request and sends it to the introspection endpoint, along with the resource server’s credentials. The response that comes back contains the scopes for the token, among other things. The resource server can then decide what it wants to do with that.</div><div class=""><br class=""></div><div class="">&nbsp;— Justin</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Sep 3, 2015, at 4:30 PM, Yannick Béot &lt;<a href="mailto:yannick.beot@gmail.com" class="">yannick.beot@gmail.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div dir="ltr" class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class=""><div class="">Hi,<br class=""><br class=""></div>Thanks Justin for the explanation. I just ran into the same issue and I could not figure what was wrong...<br class=""></div>However, I'm probably missing something.<br class=""></div>How a resource server is supposed to check the access token and get the scope?<br class=""></div>In order for my RS to query the introspection endpoint, I create a specific client.<br class=""></div>Therefore, I have the client A, a single page app for instance, and a client B, the resource server.<br class=""></div>My single page app is requesting an access token to MITREid and send it to B in REST query. B is using its own credential to query the introspection endpoint and validate the access token.<br class=""><br class=""></div>What do you think?<br class=""><br class=""></div>Yannick<br class=""></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Thu, Aug 27, 2015 at 12:48 PM, Justin Richer <span dir="ltr" class="">&lt;<a href="mailto:jricher@mit.edu" target="_blank" class="">jricher@mit.edu</a>&gt;</span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000" class="">
    The rationale behind this functionality is that you don't want to
    inadvertently leak information to a protected resource about the
    overall reach of a token if the token is usable beyond that
    particular protected resource. Let's say I have two resources, "A"
    and "B", and they have associated scopes, "a" and "b". If the client
    gets a token with scope "a b" and plays it at "A", we might not want
    "A" to inadvertently discover that the token could also be used at
    "B".<br class="">
    <br class="">
    I would not recommend removing the check entirely, <i class="">however</i>:
    the behavior has changed in version <b class="">1.2.0</b> such that the
    server doesn't return an error anymore, but instead returns only the
    scopes associated with the protected resource. In the scenario
    above, when "A" introspects the token with "a b", it gets back a
    response that only includes "a" in the scope field, while "B" would
    get back a response that only includes "b" in the scope field of the
    same token.<br class="">
    <br class="">
    &nbsp;-- Justin<div class=""><div class="h5"><br class="">
    <br class="">
    <div class="">On 8/27/2015 4:12 AM, Zaninetta Stefano
      wrote:<br class="">
    </div>
    </div></div><blockquote type="cite" class=""><div class=""><div class="h5">
      
      
      <div style="direction: ltr; font-family: Tahoma; font-size: 10pt;" class="">Hello,<br class="">
        <br class="">
        I noticed that the Introspection endpoint is returning 403 if
        the introspecting client configuration doesn't include all the
        scopes associated with the introspected token.<br class="">
        (<a href="https://github.com/mitreid-connect/OpenID-Connect-Java-Spring-Server/blob/mitreid-connect-1.1.15/openid-connect-server/src/main/java/org/mitre/oauth2/web/IntrospectionEndpoint.java#L130" target="_blank" class="">https://github.com/mitreid-connect/OpenID-Connect-Java-Spring-Server/blob/mitreid-connect-1.1.15/openid-connect-server/src/main/java/org/mitre/oauth2/web/IntrospectionEndpoint.java#L130</a>)<br class="">
        <br class="">
        I don't understand what is the reason of for that check and I
        couldn't find such recommendation in the latest specs
        (<a href="https://tools.ietf.org/html/draft-ietf-oauth-introspection-11" target="_blank" class="">https://tools.ietf.org/html/draft-ietf-oauth-introspection-11</a>).<br class="">
        Could anyone explain me what is the rationale behind that?<br class="">
        <br class="">
        At the moment the workaround we adopted is to configure all the
        available scopes for all the clients used by the Protected
        Resources; that is equivalent to skip the check.<br class="">
        Hence, I was considering removing it from the code, but I want
        to be sure I'm not missing any security implication.<br class="">
        <br class="">
        Thanks a lot,<br class="">
        Stefano<br class="">
      </div>
      <br class="">
      <fieldset class=""></fieldset>
      <br class="">
      </div></div><pre class="">_______________________________________________
mitreid-connect mailing list
<a href="mailto:mitreid-connect@mit.edu" target="_blank" class="">mitreid-connect@mit.edu</a>
<a href="http://mailman.mit.edu/mailman/listinfo/mitreid-connect" target="_blank" class="">http://mailman.mit.edu/mailman/listinfo/mitreid-connect</a>
</pre>
    </blockquote>
    <br class="">
  </div>

<br class="">_______________________________________________<br class="">
mitreid-connect mailing list<br class="">
<a href="mailto:mitreid-connect@mit.edu" class="">mitreid-connect@mit.edu</a><br class="">
<a href="http://mailman.mit.edu/mailman/listinfo/mitreid-connect" rel="noreferrer" target="_blank" class="">http://mailman.mit.edu/mailman/listinfo/mitreid-connect</a><br class="">
<br class=""></blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></div></body></html>