Re: [jose] Should we delete the "typ" header field

Richard Barnes <rlb@ipv.sx> Wed, 29 May 2013 22:45 UTC

Return-Path: <rlb@ipv.sx>
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 C9F9D21F9626 for <jose@ietfa.amsl.com>; Wed, 29 May 2013 15:45:13 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 0.057
X-Spam-Level:
X-Spam-Status: No, score=0.057 tagged_above=-999 required=5 tests=[AWL=-1.300, BAYES_00=-2.599, FH_RELAY_NODNS=1.451, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RCVD_IN_PBL=0.905, RCVD_IN_SORBS_DUL=0.877, RDNS_NONE=0.1]
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 BWd1luI2BcCM for <jose@ietfa.amsl.com>; Wed, 29 May 2013 15:45:08 -0700 (PDT)
Received: from mail-ob0-x230.google.com (mail-ob0-x230.google.com [IPv6:2607:f8b0:4003:c01::230]) by ietfa.amsl.com (Postfix) with ESMTP id 2183E21F96FE for <jose@ietf.org>; Wed, 29 May 2013 15:44:54 -0700 (PDT)
Received: by mail-ob0-f176.google.com with SMTP id v19so3950043obq.7 for <jose@ietf.org>; Wed, 29 May 2013 15:44:54 -0700 (PDT)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-originating-ip:in-reply-to:references:date :message-id:subject:from:to:cc:content-type:x-gm-message-state; bh=5ih6B33yyxRDXFf58Ob+a069GarAoXD62PBj7b/FrJg=; b=WJuq2emww2ZaiMPicvJFUtkBjqnUlpwdp+c1qjIsyr0Ecd4Evy6EoaQxEIsjsQynHX QVvvfVt93DiVMvN7BS+VqDx85XuZZWDNt1sC1pk0BtQWgtaB7Mw88PvRdA7NaAn60M5b qX1AfupCfEi/ioOsPSfhyEL8WPoeSjMAu0n+kjYpACxbRG+uOLJunnbD7P6ah5eM5/05 LMR4B/UQ2Tu4gjora/v2bR9B/KwtpjowwAUJaKdl4VgrqCgE9fij6oCBkG+XmEbME+Uh MuNY4+sv44bk8hA+fCPiNiVyKU9DI5Pwi6wjy2REfvkOkIfXqacZR2kD/gY2pZWNVNdV qmuw==
MIME-Version: 1.0
X-Received: by 10.182.153.5 with SMTP id vc5mr2978241obb.32.1369867494443; Wed, 29 May 2013 15:44:54 -0700 (PDT)
Received: by 10.60.17.9 with HTTP; Wed, 29 May 2013 15:44:54 -0700 (PDT)
X-Originating-IP: [108.18.40.68]
In-Reply-To: <02b701ce5cb8$46ae77e0$d40b67a0$@augustcellars.com>
References: <02b701ce5cb8$46ae77e0$d40b67a0$@augustcellars.com>
Date: Wed, 29 May 2013 18:44:54 -0400
Message-ID: <CAL02cgR+upF3DcS3XoviAucdje_4ctjhCDTNS53WsAOBzDoM8Q@mail.gmail.com>
From: Richard Barnes <rlb@ipv.sx>
To: Jim Schaad <ietf@augustcellars.com>
Content-Type: multipart/alternative; boundary="089e013a0ada655eff04dde32123"
X-Gm-Message-State: ALoCoQlkwqqK97GksmZBQSG11EUyxDON/5yOxQMerTsmMHk9AGES77dSiMrgFCIALlLx9UYkA/lT
Cc: "jose@ietf.org" <jose@ietf.org>
Subject: Re: [jose] Should we delete the "typ" header field
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, 29 May 2013 22:45:13 -0000

As I understand it, "typ" lets you look at an object and tell if it's a JWE
or JWS.  That seems handy enough to keep around.

Depending on how we do MIME types, it might even be necessary, namely if we
have a single application/jose type. I forget if that's the case in the
current docs.


On Wednesday, May 29, 2013, Jim Schaad wrote:

> In reading the documents, I am trying to understand the justification for
> having the “typ” header parameter in the JOSE documents.****
>
> ** **
>
> The purpose of the field is to hold the type of the object.  In the past,
> I believe that values which should now be placed in the cty field (such as
> “JWT”) were placed in this field as well.  However the parameter is
> optional and an implementation cannot rely on its being present.  This
> means that for all practical purposes all of the code to determine the
> value of the type field from the values of the alg and enc fields.  If the
> field was mandatory then this code would disappear at a fairly small space
> cost and I can understand why the parameter would be present.****
>
> ** **
>
> Can anybody justify why this field should be present in the document – or
> should it just disappear?****
>
> ** **
>
> Jim****
>
> ** **
>