Re: [OAUTH-WG] Question lengths in draft-sakimura-oauth-tcse-03

Bill Mills <wmills_92105@yahoo.com> Fri, 16 May 2014 21:27 UTC

Return-Path: <wmills_92105@yahoo.com>
X-Original-To: oauth@ietfa.amsl.com
Delivered-To: oauth@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 39ECC1A0248 for <oauth@ietfa.amsl.com>; Fri, 16 May 2014 14:27:33 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.14
X-Spam-Level:
X-Spam-Status: No, score=-2.14 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, FREEMAIL_REPLYTO_END_DIGIT=0.25, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RP_MATCHES_RCVD=-0.651, SPF_PASS=-0.001, T_REMOTE_IMAGE=0.01] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aAVMdBsfdJ7O for <oauth@ietfa.amsl.com>; Fri, 16 May 2014 14:27:30 -0700 (PDT)
Received: from nm10-vm0.bullet.mail.bf1.yahoo.com (nm10-vm0.bullet.mail.bf1.yahoo.com [98.139.213.147]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 977D41A0157 for <oauth@ietf.org>; Fri, 16 May 2014 14:27:29 -0700 (PDT)
Received: from [66.196.81.170] by nm10.bullet.mail.bf1.yahoo.com with NNFMP; 16 May 2014 21:27:21 -0000
Received: from [98.139.212.240] by tm16.bullet.mail.bf1.yahoo.com with NNFMP; 16 May 2014 21:27:21 -0000
Received: from [127.0.0.1] by omp1049.mail.bf1.yahoo.com with NNFMP; 16 May 2014 21:27:21 -0000
X-Yahoo-Newman-Property: ymail-3
X-Yahoo-Newman-Id: 378744.73708.bm@omp1049.mail.bf1.yahoo.com
Received: (qmail 90411 invoked by uid 60001); 16 May 2014 21:27:21 -0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1400275641; bh=06EFPWT1hvQ2iagOC5SSLF2KgDZd+nGa0ySz2Me6RTs=; h=References:Message-ID:Date:From:Reply-To:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type; b=0n1t5qrysrafnt8xWvKIploB7zScKLogM6nfy5AC76ER2TZfL+8Aa2plgfPEheC/Ujn+REsnFpKABEFZLpCIksZHpcW0Yxz9f+lGKXNuxlW2FAyfJEZ5Cvirg9w7fDDioQIhDfwCJHRIUhQDEeAQ4HZidHmfXWNDhHUbMkNycVw=
X-YMail-OSG: IYGueooVM1myaY78c7txIJMK2N9AzonCz0g5IGxL9cTUitw sfSdXAm8l0.J0VDhbfHS93etKHEcYmnVuItcAjAkwYwOMdhy38fME5yU2bA3 WHNsiGbpVSiE_MjESROfAjA0XFa1p3rgHfgYsqy5S25EV615JR434yX6f_QG .6DSb9xecPugpwWGey3WGgu0z0IQdfRCqG8jdDKH6qY6tiDmBZBeqKWQ_65Z Jra3mYz.kgj2hIxW8Mv.GYfP8bBlVc2q.HYnQFCY7JeFiJ7b9lr3KFUiGPoa giF1wOMo09zeTrNoQKkhFgxULNil0tuhPkSrrYSrGb9aFc9ev2SpxoMEqQgJ orQRQGhqZU_rU8Ht4NmVT3KeIvYkmEh2g2PdQYgkxDCdn_kyMn.YeBtajYue oUZpxaE2K4BsXIBxd3zkJ18gW4vm_BOIcjjdi_E33gKainF070WoTVEAIZ7E o4Gan9rAHgxYbSyLzhhya0wPziKWi42AullSAA3T2ql1MUhm7N_jJLQkiF51 vJRF4xVwBNz4BgFPn0UWYiwhzk3NqVkAwgmLD3Bg7wMVGVOdQx.5XHm4my7j aHk9ZQxMlLgHjPM0KMq9I3Q2w9qEoEXQFqPvSrqj8d3FzKbsTPmTPkRt_PXZ OJi8dvw--
Received: from [209.131.62.113] by web142803.mail.bf1.yahoo.com via HTTP; Fri, 16 May 2014 14:27:21 PDT
X-Rocket-MIMEInfo: 002.001, VGhlIEhUVFAgc3BlY3MgZG9uJ3QgbGltaXQgdGhlc2UgdGhpbmdzLCBidXQgaW1wbGVtZW50YXRpb25zIGRvLCBhbmQgdGhlIHByb2JsZW1zIHdoZW4geW91IHJ1biBpbnRvIHRoZW0gYXJlIGEgcmVhIHBhaW4uCgpETyB3ZSB3YW50IHRvIG1ha2UgdGhpcyBhIGhhcmQgbGltaXQsIG9yIHNob3VsZCBpdCBiZSBndWlkYW5jZSBpbiB0aGUgZm9ybSBvZiBSRUNPTU1FTkRFRCBvciBTSE9VTEQ_CgoKT24gRnJpZGF5LCBNYXkgMTYsIDIwMTQgOTozNSBBTSwgQnJpYW4gQ2FtcGJlbGwgPGJjYW1wYmVsbEBwaW5naWQBMAEBAQE-
X-Mailer: YahooMailWebService/0.8.188.663
References: <CA+k3eCTZOheb0HCetS88EXcP-8LJQrYPRuwVcd4NWaWxUAVO1g@mail.gmail.com> <sjm4n0uk8be.fsf@mocana.ihtfp.org> <21A361B0-4E8F-4DAB-9EEB-D48FBCBDFFED@ve7jtb.com> <CA+k3eCQJRymEDERy=3yvioetg-7Tz025gaZJ1FS4DYmkTGRhcQ@mail.gmail.com> <CA+k3eCTguJMR-94-KyfpT2_3kQZQQgH3QV6VwawPLoSnBxqVbQ@mail.gmail.com> <CABzCy2DvNsL79JHcR8LoNd1riaC9_KjTXBO1+xUTfCv2NHCOyA@mail.gmail.com> <CA+k3eCQLdfmY_q3Avjc-FKUUK-wq6gEP-j+YE85dkNnhr5=Y4w@mail.gmail.com> <CABzCy2DHTxv6W+u171ZrgBeL0NJZ0jkY33YVWDnsPhuCZfJ26g@mail.gmail.com> <E54A312A-F44C-4E13-9DD7-C47DC48CA805@ve7jtb.com> <CA+k3eCS=vt_WDpGYJ6LcsF_MO0GkoebH6NrQ--NTD0E20NOQ8A@mail.gmail.com>
Message-ID: <1400275641.37471.YahooMailNeo@web142803.mail.bf1.yahoo.com>
Date: Fri, 16 May 2014 14:27:21 -0700
From: Bill Mills <wmills_92105@yahoo.com>
To: Brian Campbell <bcampbell@pingidentity.com>, John Bradley <ve7jtb@ve7jtb.com>
In-Reply-To: <CA+k3eCS=vt_WDpGYJ6LcsF_MO0GkoebH6NrQ--NTD0E20NOQ8A@mail.gmail.com>
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="905790552-1123540662-1400275641=:37471"
Archived-At: http://mailarchive.ietf.org/arch/msg/oauth/hsKG14g5R3dSSWmk9JJSYfzr8KY
Cc: oauth <oauth@ietf.org>, Naveen Agarwal <naa@google.com>
Subject: Re: [OAUTH-WG] Question lengths in draft-sakimura-oauth-tcse-03
X-BeenThere: oauth@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
Reply-To: Bill Mills <wmills_92105@yahoo.com>
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: Fri, 16 May 2014 21:27:33 -0000

The HTTP specs don't limit these things, but implementations do, and the problems when you run into them are a rea pain.

DO we want to make this a hard limit, or should it be guidance in the form of RECOMMENDED or SHOULD?


On Friday, May 16, 2014 9:35 AM, Brian Campbell <bcampbell@pingidentity.com> wrote:
 
Yeah, I agree with John here. There are a few good reasons to restrict the length of the code_challenge. One is trying to keep the authorization request URI to reasonable size as it will eventually run into various limits on clients and/or servers. The other is constraining the amount of data that an AS needs to store per code.






On Fri, May 16, 2014 at 7:41 AM, John Bradley <ve7jtb@ve7jtb.com> wrote:

From the AS side you probably want to know what the max size you need to store per code.
>
>
>
>On the call to the token endpoint it is a POST so size should not be an issue.  
>
>
>
>
>On May 16, 2014, at 3:10 PM, Nat Sakimura <sakimura@gmail.com> wrote:
>
>Now that I cannot remember what limit we were hitting, it might be a good idea to remove the constraint and see if anyone protests. 
>>
>>
>>What do you think? 
>>
>>
>>Nat
>>
>>
>>
>>2014-05-14 20:46 GMT+09:00 Brian Campbell <bcampbell@pingidentity.com>:
>>
>>That too would suggest that the length limit be on code_challenge because that's the parameter that will be on URIs getting passed around. The code_verifier is sent directly in the POST body from client to AS. 
>>>
>>>
>>>
>>>
>>>On Tue, May 13, 2014 at 12:52 AM, Nat Sakimura <sakimura@gmail.com> wrote:
>>>
>>>+1 for octet. We used to have "bytes" in JW* so I used "bytes" here, while at the same time complaining in Jose that it should be "octet". JW* changed to "octet" but I failed to sync with it in the last few edits. 
>>>>
>>>>
>>>>I do not quite remember which platform, but the reason for the limit was that some platform had some limitations as to the length of the sting to be passed to it through URI and we did not want the challenges to be truncated by that limit. 
>>>>
>>>>
>>>>Best, 
>>>>
>>>>
>>>>Nat
>>>>
>>>>
>>>>
>>>>2014-05-13 6:56 GMT+09:00 Brian Campbell <bcampbell@pingidentity.com>:
>>>>
>>>>
>>>>And it'd give the AS some direct guidance on protecting itself from crazy long code_challenge values rather than relying on the client not to do something creative. 
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>On Mon, May 12, 2014 at 3:54 PM, Brian Campbell <bcampbell@pingidentity.com> wrote:
>>>>>
>>>>>Right but that's why I'm asking why not just put the limit on code_challange rather than inferring it from code_verifyer + challenge algorithm, which probably bounds it but doesn't necessarily do so? It's not a big deal but would read more clearly, I think.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>On Mon, May 12, 2014 at 3:48 PM, John Bradley <ve7jtb@ve7jtb.com> wrote:
>>>>>>
>>>>>>I think octets is more consistent with other JW* and OAuth specs.
>>>>>>>
>>>>>>>The code_challange is the same length as the code_verifyer or is a hash of the code_verifyer so likely smaller than 128octets (43 ish for base64 256 bit)
>>>>>>>
>>>>>>>Limiting the code_verifyer size sets the upper bound for code_challange, unless someone comes up with a really creative code challenge algorithm.
>>>>>>>
>>>>>>>I will talk to nat about changing it to octets when I see him tomorrow.
>>>>>>>
>>>>>>>John B.
>>>>>>>
>>>>>>>
>>>>>>>On May 12, 2014, at 11:15 PM, Derek Atkins <warlord@MIT.EDU> wrote:
>>>>>>>
>>>>>>>> Brian Campbell <bcampbell@pingidentity.com> writes:
>>>>>>>>
>>>>>>>>> I notice that code_verifier is defined as "high entropy cryptographic random
>>>>>>>>> string of length less than 128 bytes"  [1], which brought a few questions and
>>>>>>>>> comments to mind. So here goes:
>>>>>>>>>
>>>>>>>>> Talking about the length of a string in terms of bytes is always potentially
>>>>>>>>> confusing. Maybe characters would be an easier unit for people like me to wrap
>>>>>>>>> their little brains around?
>>>>>>>>
>>>>>>>> It depends if it really is characters or bytes.  For example there are
>>>>>>>> many multi-byte UTF-8 characters, so if it really is bytes then saying
>>>>>>>> characters is wrong because it could overflow.  So let's make sure we
>>>>>>>> know what we're talking about.  Historically, if we're talking bytes the
>>>>>>>> IETF often uses the phrase "octets".  Would that be less confusing?
>>>>>>>>
>>>>>>>>> Why are we putting a length restriction on the code_verifier anyway? It seems
>>>>>>>>> like it'd be more appropriate to restrict the length of the code_challenge
>>>>>>>>> because that's the thing the AS will have to maintain somehow (store in a DB
>>>>>>>>> or memory or encrypt into the code). Am I missing something here?
>>>>>>>>>
>>>>>>>>> Let me also say that I hadn't looked at this document since its early days in
>>>>>>>>> draft -00 or -01 last summer but I like the changes and how it's been kept
>>>>>>>>> pretty simple for the common use-case while still allowing for crypto agility/
>>>>>>>>> extension. Nice work!
>>>>>>>>>
>>>>>>>>> [1] http://tools.ietf.org/html/draft-sakimura-oauth-tcse-03#section-3.3
>>>>>>>>
>>>>>>>> -derek
>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> OAuth mailing list
>>>>>>>>> OAuth@ietf.org
>>>>>>>>> https://www.ietf.org/mailman/listinfo/oauth
>>>>>>>>
>>>>>>>> --
>>>>>>>>       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
>>>>>>>>       Member, MIT Student Information Processing Board  (SIPB)
>>>>>>>>       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
>>>>>>>>       warlord@MIT.EDU                        PGP key available
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>-- 
>>>>>>
>>>>>> Brian Campbell
>>>>>>Portfolio Architect
>>>>>>@ bcampbell@pingidentity.com 
>>>>>> +1 720.317.2061 
>>>>>>Connect with us…           
>>>>>>
>>>>>
>>>>>
>>>>>-- 
>>>>>
>>>>> Brian Campbell
>>>>>Portfolio Architect
>>>>>@ bcampbell@pingidentity.com 
>>>>> +1 720.317.2061 
>>>>>Connect with us…           
>>>>>
>>>>>_______________________________________________
>>>>>OAuth mailing list
>>>>>OAuth@ietf.org
>>>>>https://www.ietf.org/mailman/listinfo/oauth
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>>-- 
>>>>Nat Sakimura (=nat)
>>>>Chairman, OpenID Foundation
>>>>http://nat.sakimura.org/
>>>>@_nat_en
>>>
>>>
>>>-- 
>>>
>>> Brian Campbell
>>>Portfolio Architect
>>>@ bcampbell@pingidentity.com 
>>> +1 720.317.2061 
>>>Connect with us…           
>>>
>>
>>
>>
>>-- 
>>Nat Sakimura (=nat)
>>Chairman, OpenID Foundation
>>http://nat.sakimura.org/
>>@_nat_en
>


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