Re: [jose] #20: Shorter names for JSON serialization

"Manger, James H" <James.H.Manger@team.telstra.com> Wed, 08 May 2013 00:50 UTC

Return-Path: <James.H.Manger@team.telstra.com>
X-Original-To: jose@ietfa.amsl.com
Delivered-To: jose@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6535611E80E0 for <jose@ietfa.amsl.com>; Tue, 7 May 2013 17:50:07 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.9
X-Spam-Level:
X-Spam-Status: No, score=-0.9 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, HELO_EQ_AU=0.377, HOST_EQ_AU=0.327, HTML_MESSAGE=0.001, RELAY_IS_203=0.994]
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 lUz8a5qwQtPi for <jose@ietfa.amsl.com>; Tue, 7 May 2013 17:50:02 -0700 (PDT)
Received: from ipxcvo.tcif.telstra.com.au (ipxcvo.tcif.telstra.com.au [203.35.135.208]) by ietfa.amsl.com (Postfix) with ESMTP id DE25F11E80D7 for <jose@ietf.org>; Tue, 7 May 2013 17:50:00 -0700 (PDT)
X-IronPort-AV: E=Sophos; i="4.87,631,1363093200"; d="scan'208,217"; a="134318581"
Received: from unknown (HELO ipcdvi.tcif.telstra.com.au) ([10.97.217.212]) by ipocvi.tcif.telstra.com.au with ESMTP; 08 May 2013 10:49:59 +1000
X-IronPort-AV: E=McAfee;i="5400,1158,7067"; a="130615262"
Received: from wsmsg3701.srv.dir.telstra.com ([172.49.40.169]) by ipcdvi.tcif.telstra.com.au with ESMTP; 08 May 2013 10:49:59 +1000
Received: from WSMSG3153V.srv.dir.telstra.com ([172.49.40.159]) by WSMSG3701.srv.dir.telstra.com ([172.49.40.169]) with mapi; Wed, 8 May 2013 10:49:59 +1000
From: "Manger, James H" <James.H.Manger@team.telstra.com>
To: Mike Jones <Michael.Jones@microsoft.com>, Richard Barnes <rlb@ipv.sx>, Jim Schaad <ietf@augustcellars.com>
Date: Wed, 08 May 2013 10:49:57 +1000
Thread-Topic: [jose] #20: Shorter names for JSON serialization
Thread-Index: AQHOSokGUnVw7/2APkGvFZmOHgLmz5j4soMAgAGN86CAACDRcIAAEZKQgAAAy2A=
Message-ID: <255B9BB34FB7D647A506DC292726F6E1150D2FAE61@WSMSG3153V.srv.dir.telstra.com>
References: <049.92c9829790c8d5776a0efee36c11df4c@trac.tools.ietf.org> <00a601ce4a88$dc8cdd70$95a69850$@augustcellars.com> <CAL02cgRNPVpiOrz+7SxNEcsNJAgCGg1dic2h+YX2FnVRZh_4wg@mail.gmail.com> <4E1F6AAD24975D4BA5B16804296739436771242B@TK5EX14MBXC283.redmond.corp.microsoft.com> <255B9BB34FB7D647A506DC292726F6E1150D2FADD4@WSMSG3153V.srv.dir.telstra.com> <4E1F6AAD24975D4BA5B168042967394367712FDA@TK5EX14MBXC283.redmond.corp.microsoft.com>
In-Reply-To: <4E1F6AAD24975D4BA5B168042967394367712FDA@TK5EX14MBXC283.redmond.corp.microsoft.com>
Accept-Language: en-US, en-AU
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
acceptlanguage: en-US, en-AU
Content-Type: multipart/alternative; boundary="_000_255B9BB34FB7D647A506DC292726F6E1150D2FAE61WSMSG3153Vsrv_"
MIME-Version: 1.0
Cc: "draft-ietf-jose-json-web-encryption@tools.ietf.org" <draft-ietf-jose-json-web-encryption@tools.ietf.org>, jose issue tracker <trac+jose@trac.tools.ietf.org>, "jose@ietf.org" <jose@ietf.org>
Subject: Re: [jose] #20: Shorter names for JSON serialization
X-BeenThere: jose@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Javascript Object Signing and Encryption <jose.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jose>, <mailto:jose-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/jose>
List-Post: <mailto:jose@ietf.org>
List-Help: <mailto:jose-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jose>, <mailto:jose-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 08 May 2013 00:50:07 -0000

RFC 4106 “GCM in IPsec ESP” uses the terms “IV” and “nonce”. It uses “nonce” for the 12-byte quantity used in the GCM algorithm, and “IV” for an 8-byte subset of that. That is, it uses “nonce” for the value JWE currently labels “iv”.

RFC 4106 section 2 “AES-GCM” says:
   For clarity, we refer to the AES-GCM IV as a
   nonce in the context of AES-GCM-ESP.  The same nonce and key
   combination MUST NOT be used more than once.
In section 4:

   The nonce passed to the GCM-AES encryption algorithm has the

   following layout:

There is some unavoidable historical confusion with the terms “iv” and “nonce” (even whether IV means initialization vector or initialization value). In my opionion, the RFCs that do the best job of avoiding confusion are the one using “nonce”.

--
James Manger

From: jose-bounces@ietf.org [mailto:jose-bounces@ietf.org] On Behalf Of Mike Jones
Sent: Wednesday, 8 May 2013 10:37 AM
To: Manger, James H; Richard Barnes; Jim Schaad
Cc: draft-ietf-jose-json-web-encryption@tools.ietf.org; jose issue tracker; jose@ietf.org
Subject: Re: [jose] #20: Shorter names for JSON serialization

http://tools.ietf.org/html/rfc4106 calls it “Initialization Vector (IV)” so I think the reasonable choices are either “initialization_vector” (the current name) or “iv” (the possible shortened name).  “Nonce” means very different things in other protocols, so I think we really should steer completely clear of it, to prevent confusion.

                                                            -- Mike

From: Manger, James H [mailto:James.H.Manger@team.telstra.com]
Sent: Tuesday, May 07, 2013 5:34 PM
To: Mike Jones; Richard Barnes; Jim Schaad
Cc: draft-ietf-jose-json-web-encryption@tools.ietf.org<mailto:draft-ietf-jose-json-web-encryption@tools.ietf.org>; jose issue tracker; jose@ietf.org<mailto:jose@ietf.org>
Subject: RE: [jose] #20: Shorter names for JSON serialization

How about “nonce”, instead of “iv”?

“nonce” is used for the equivalent field in other RFCs about AEAD algorithms: RFC 5116 AEAD, RFC 5297 SIV, RFC 3610 CCM. Some of these use the name “IV” for different things than the AEAD nonce.
NIST 800-38D GCM does uses “IV”, though it is defined as “A nonce that is associated with an invocation of authenticated encryption on a particular plaintext and AAD”. RFC 5084 “CCM & GCM in CMS” even says:
  “To have a common set of terms for AES-CCM and AES-GCM, the AES-GCM IV is referred to as a nonce in the remainder of this document.”

--
James Manger

From: jose-bounces@ietf.org<mailto:jose-bounces@ietf.org> [mailto:jose-bounces@ietf.org] On Behalf Of Mike Jones
Sent: Wednesday, 8 May 2013 7:41 AM
To: Richard Barnes; Jim Schaad
Cc: draft-ietf-jose-json-web-encryption@tools.ietf.org<mailto:draft-ietf-jose-json-web-encryption@tools.ietf.org>; jose issue tracker; jose@ietf.org<mailto:jose@ietf.org>
Subject: Re: [jose] #20: Shorter names for JSON serialization

What about “iv” and “tag”?  For the other names, I’d actually prefer staying with those that are full words rather than those that are abbreviations of words, since they’re more descriptive.  But I agree that “initialization_vector” and “authentication_tag” were overkill.

                                                            -- Mike