[mitreid-connect] Client credentials security issue?

Justin Richer jricher at mit.edu
Mon Jul 10 09:46:52 EDT 2017


Can you send me, off list, transcripts of the http transactions? 


--Justin
 Sent from my phone
-------- Original message --------From: Luiz Omori <luiz.omori at duke.edu> Date: 7/10/17  9:08 AM  (GMT-05:00) To: Justin Richer <jricher at mit.edu> Cc: mitreid-connect at mit.edu Subject: Re: [mitreid-connect] Client credentials security issue? 


I can reproduce this behaviour with
https://mitreid.org.
 
1.      
Perform Authorization Code flow to successfully acquire an access token. Not sure if it matters, but I’ve created my own client, Duke.
2.      
Perform client credentials using the same client above. Server responded with an ID Token. My request didn’t contain any scopes.
 
Yes, I had seen the exact line of code you are talking about. It could be a problem in my environment, but I didn’t see it being hit for the client credentials flow when I was debugging
 my local instance.
 
Regards,
Luiz
 

From: 
Justin Richer <jricher at mit.edu>

Date: Friday, July 7, 2017 at 5:36 PM

To: Luiz Omori <luiz.omori at duke.edu>

Cc: "mitreid-connect at mit.edu" <mitreid-connect at mit.edu>

Subject: Re: [mitreid-connect] Client credentials security issue?


 

I just tried this on the mitreid.org test
 server and I couldn’t replicate it. Then I checked the code and what you’re describing is prevented by this line in ConnectTokenEnhancer:

 



if (originalAuthRequest.getScope().contains(SystemScopeService.OPENID_SCOPE)


&& !authentication.isClientOnly()) {



 


If you do get an ID token at all through some fluke, it should refer to the client that authenticated, as that’s the authenticated “user” in that scenario. Same deal with token introspection of access tokens. 



 


 — Justin


 



On Jul 7, 2017, at 4:26 PM, Luiz Omori <luiz.omori at duke.edu> wrote:

 


Hi,


 


I’ve just run by chance into a suspicious behaviour while exercising the Client Credentials flow. Along with the request I’ve sent scope=openid offline_access.
 Interesting enough, I got an id_token back. That id-token was referring to a user that I used for an Authorization Code request done immediately before the Client Credentials call. My usage of scope for the Client Credentials may or may not be legal, but in
 any case I don’t think the server should be sending an ID Token back for Client Credentials. I’m using server version 1.3.1.


 


Regards,


Luiz

_______________________________________________

mitreid-connect mailing list

mitreid-connect at mit.edu

http://mailman.mit.edu/mailman/listinfo/mitreid-connect



 



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/mitreid-connect/attachments/20170710/5bfedcf5/attachment-0001.html


More information about the mitreid-connect mailing list