Yes if the AS is encoding state + redirect_uri and grants in the code then it 
could get big.  
In that case you probably would put a hash of the state in the code to manage 
size.  The alg would be up to the AS, as long as it used the same hash both 
places it would work.

Sending the state to the token endpoint is like having nonce and c_hash in the 
id_token, it binds the issued code to the browser instance.

This protects against codes that leak via redirect uri pattern matching. 
failures etc.  It prevents an attacker from being able to replay a code from a 
different browser.

If the client implements the other mitigations on the authorization endpoint, 
then it wouldn't be leaking the code via the token endpoint. 

The two mitigations are for different attacks, however some of the attacks 
combined both vulnerabilities.

Sending the iss and client_id is enough to stop the confused client attacks, 
but sending state on its own would not have stopped all of them.

We discussed having them in separate drafts, and may still do that.   However 
for discussion having them in one document is I think better in the short run.

John B.

> On Jan 21, 2016, at 4:48 PM, David Waite <da...@alkaline-solutions.com> wrote:
> 
> Question: 
> 
> I understand how “iss" helps mitigate this attack (client knows response was 
> from the appropriate issuer and not an attack where the request was answered 
> by another issuer). 
> 
> However, how does passing “state” on the authorization_code grant token 
> request help once you have the above in place? Is this against some alternate 
> flow of this attack I don’t see, or is it meant to mitigate some entirely 
> separate attack?
> 
> If one is attempting to work statelessly (e.g. your “state” parameter is 
> actual state and not just a randomly generated value), a client would have 
> always needed some way to differentiate which issuer the authorization_code 
> grant token request would be sent to.
> 
> However, if an AS was treating “code” as a token (for instance, encoding: 
> client, user, consent time and approved scopes), the AS now has to include 
> the client’s state as well. This would effectively double (likely more with 
> encoding) the state sent in the authorization response back to the client 
> redirect URL, adding more pressure against maximum URL sizes.
> 
> -DW
> 
>> On Jan 20, 2016, at 11:28 PM, Mike Jones <michael.jo...@microsoft.com 
>> <mailto:michael.jo...@microsoft.com>> wrote:
>> 
>> John Bradley and I collaborated to create the second OAuth 2.0 Mix-Up 
>> Mitigation draft.  Changes were:
>> ·       Simplified by no longer specifying the signed JWT method for 
>> returning the mitigation information.
>> ·       Simplified by no longer depending upon publication of a discovery 
>> metadata document.
>> ·       Added the “state” token request parameter.
>> ·       Added examples.
>> ·       Added John Bradley as an editor.
>>  
>> The specification is available at:
>> ·       http://tools.ietf.org/html/draft-jones-oauth-mix-up-mitigation-01 
>> <http://tools.ietf.org/html/draft-jones-oauth-mix-up-mitigation-01>
>>  
>> An HTML-formatted version is also available at:
>> ·       
>> http://self-issued.info/docs/draft-jones-oauth-mix-up-mitigation-01.html 
>> <http://self-issued.info/docs/draft-jones-oauth-mix-up-mitigation-01.html>
>>  
>>                                                           -- Mike
>>  
>> P.S.  This note was also posted at http://self-issued.info/?p=1526 
>> <http://self-issued.info/?p=1526> and as @selfissued 
>> <https://twitter.com/selfissued>.
>>  
>> _______________________________________________
>> OAuth mailing list
>> OAuth@ietf.org <mailto:OAuth@ietf.org>
>> https://www.ietf.org/mailman/listinfo/oauth 
>> <https://www.ietf.org/mailman/listinfo/oauth>
> _______________________________________________
> OAuth mailing list
> OAuth@ietf.org
> https://www.ietf.org/mailman/listinfo/oauth

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________
OAuth mailing list
OAuth@ietf.org
https://www.ietf.org/mailman/listinfo/oauth

Reply via email to