Re: [Rats] [COSE] [Anima] cose+cbor vs cwt in MIME types

"Smith, Ned" <ned.smith@intel.com> Tue, 04 April 2023 19:45 UTC

Return-Path: <ned.smith@intel.com>
X-Original-To: rats@ietfa.amsl.com
Delivered-To: rats@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id BB9ADC1526F4; Tue, 4 Apr 2023 12:45:57 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.392
X-Spam-Level:
X-Spam-Status: No, score=-4.392 tagged_above=-999 required=5 tests=[AC_DIV_BONANZA=0.001, BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=intel.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dQCWcVyXF5MO; Tue, 4 Apr 2023 12:45:53 -0700 (PDT)
Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 248B5C15257A; Tue, 4 Apr 2023 12:45:50 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1680637553; x=1712173553; h=from:to:cc:subject:date:message-id:references: in-reply-to:mime-version; bh=K89vBZuNkpkfTmzPbNmPo7WltPuJgvBfIiP3pQzykMs=; b=krlTtWxoX963jXMhAgDPV0KXIbVjePuwhRGPMhaoD0+LhecwtGOhCPG2 NXEilpvvJPYgFpJCzj9IwPnI2FMSjObVhcl7bdmarSngPGZT7/2zDSWm3 FlmHtRdtXnsnrktgXOOnsMJJsNGtwz0c1XYKkH5mFLc7kKLKn9lvaZU52 tRT4qN2Af3TPc21aZM+BVVSUnaHW6fPDRbPic9w52DNDQq8PGRamiLkDP jQafxglOQh4Z8V+QlgEIOSofGJ/0RLPe8cplJOjCQLyyGU1huLjTpCPuJ aNoGoZ+dwLwZ5C5ywSEMEYLlH/+CmMb9QIBS7h3vUcU8BPHfAbgkZcpCi w==;
X-IronPort-AV: E=McAfee;i="6600,9927,10670"; a="370106012"
X-IronPort-AV: E=Sophos;i="5.98,318,1673942400"; d="scan'208,217";a="370106012"
Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 04 Apr 2023 12:45:48 -0700
X-ExtLoop1: 1
X-IronPort-AV: E=McAfee;i="6600,9927,10670"; a="663746396"
X-IronPort-AV: E=Sophos;i="5.98,318,1673942400"; d="scan'208,217";a="663746396"
Received: from fmsmsx602.amr.corp.intel.com ([10.18.126.82]) by orsmga006.jf.intel.com with ESMTP; 04 Apr 2023 12:45:46 -0700
Received: from fmsmsx612.amr.corp.intel.com (10.18.126.92) by fmsmsx602.amr.corp.intel.com (10.18.126.82) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Tue, 4 Apr 2023 12:45:47 -0700
Received: from fmsmsx610.amr.corp.intel.com (10.18.126.90) by fmsmsx612.amr.corp.intel.com (10.18.126.92) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Tue, 4 Apr 2023 12:45:46 -0700
Received: from FMSEDG603.ED.cps.intel.com (10.1.192.133) by fmsmsx610.amr.corp.intel.com (10.18.126.90) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21 via Frontend Transport; Tue, 4 Apr 2023 12:45:46 -0700
Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.177) by edgegateway.intel.com (192.55.55.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.21; Tue, 4 Apr 2023 12:45:12 -0700
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kKDYxlhQoka4Jva3DYvn+my45YEKWYmyhMfBfyw2VRfMjB/3sH6s/n9iAECdX55CJbWGQHtn3iYq2UAZrM+uoUF8facIjis8xvA1t7d4/9Gi6kooZs1qDfoaAv7GkBa3Fux+YQlFfvV+6ONo0j2RWPzwTg9LTiEWlZuFmHy6/G3yRqnrOjzPOyLQ2N7yCpTM/BKi32DMij7XyrhFGrIzGH3BAXIA9vyPfnxHDqVenn4x5z2146geDUP5WgLoEOlrEa6dNmraVSdDIE4cEXebwi+sahoMgVQQJH8PFFAnqAnqtovoVLN2hT8IUvGR+QqUwVbHuUHslj7Uoa7eN57Zyg==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=K89vBZuNkpkfTmzPbNmPo7WltPuJgvBfIiP3pQzykMs=; b=idkYG8VWWE9pkuRk7eIsF1HkapsJchnNV98cfYm8pQ2q4xuYmDEkGtSa5MPU84E3+B9wDYjcXIj+LXaoXh67/dr7gIWpQmz/DTQUdDm3us0BvFWNAgRRRjrpwi5mxiOPcRcHXOqQ/dOtgSRd1CJVzv/Al1sPrfa40FzyW/tfEexUE2XnUrRscAOou3/1w6YkYEjXpCmDqq8vbllOavDRdppuz19nHRDnKKEMiWpkDIh+hdgHX5FYEMGbevAMMypdYKJcd63ipVXYU9HYae0w+M7lexEvQ15f7VN5kMbFlQnmfDv9jbiuRBD2oR9VCUH0So3D4HuNIEhgrArUyNHIiA==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none
Received: from CO1PR11MB5169.namprd11.prod.outlook.com (2603:10b6:303:95::19) by BL1PR11MB5556.namprd11.prod.outlook.com (2603:10b6:208:314::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6254.26; Tue, 4 Apr 2023 19:44:57 +0000
Received: from CO1PR11MB5169.namprd11.prod.outlook.com ([fe80::4158:2ea3:b1cc:987d]) by CO1PR11MB5169.namprd11.prod.outlook.com ([fe80::4158:2ea3:b1cc:987d%5]) with mapi id 15.20.6222.033; Tue, 4 Apr 2023 19:44:57 +0000
From: "Smith, Ned" <ned.smith@intel.com>
To: Orie Steele <orie@transmute.industries>
CC: Laurence Lundblade <lgl@island-resort.com>, Esko Dijk <esko.dijk@iotconsultancy.nl>, Michael Richardson <mcr@sandelman.ca>, Thomas Fossati <Thomas.Fossati@arm.com>, Thomas Fossati <tho.ietf@gmail.com>, cose <cose@ietf.org>, rats <rats@ietf.org>, "anima@ietf.org" <anima@ietf.org>
Thread-Topic: [COSE] [Rats] [Anima] cose+cbor vs cwt in MIME types
Thread-Index: AQHZZmSk4Y670SdiD0Kan4D60z0V868Zjm2AgACaFQD//5+cAIAAfm6AgADTLoA=
Date: Tue, 04 Apr 2023 19:44:56 +0000
Message-ID: <CB59784A-7B74-4729-8055-B1334D1042BE@intel.com>
References: <167847004893.23876.9884501000866697896@ietfa.amsl.com> <DB9PR08MB6524E8F83E7149AD95B6CDB89CBA9@DB9PR08MB6524.eurprd08.prod.outlook.com> <2313611.1678640027@dyas> <DB9PR08MB6524D3E44EBF11BB83F8F9069CB99@DB9PR08MB6524.eurprd08.prod.outlook.com> <2380614.1678721850@dyas> <CAObGJnPjijJ61B_WvujcbunwW7aPA7c-CY4goPDX+yohR_kHOw@mail.gmail.com> <DB9PR08MB6524A6A7E5AABD96BBA34C8A9C879@DB9PR08MB6524.eurprd08.prod.outlook.com> <14833.1679597042@localhost> <8225.1679872718@localhost> <DU0P190MB19784AFEED440A3EBF922A87FD929@DU0P190MB1978.EURP190.PROD.OUTLOOK.COM> <4BB67CAE-73E0-43B7-86C4-76DC06379CB1@intel.com> <CAN8C-_L0VnwZaOy8QxKiDBG1dXK+Ct9X-5jzeQGFSnZwLkRzaA@mail.gmail.com> <3EC8A813-C84E-4869-83D2-ECAC2487DE97@intel.com> <CAN8C-_+z0GoNCo_Jd77DWeKN3XE76hccr5gKd90q+rm1w6haAw@mail.gmail.com> <36C7760F-4180-422C-A35B-A626DDC2A6F2@island-resort.com> <EB82CDEC-44A0-42DA-BAF1-71791B28CFDD@intel.com> <CAN8C-_JsBMHGe_5jbShKTHuvT+sZXWFk+G-MOQ9zLVMr_GVxFw@mail.gmail.com> <1A299CE1-9572-48F2-84EA-2DEB21B216C1@intel.com> <CAN8C-_KEVXxS=0ca=n0b5bC=5bpV3xgwzFSE0PrUZYWUS5rHnw@mail.gmail.com>
In-Reply-To: <CAN8C-_KEVXxS=0ca=n0b5bC=5bpV3xgwzFSE0PrUZYWUS5rHnw@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/16.71.23032500
authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com;
x-ms-publictraffictype: Email
x-ms-traffictypediagnostic: CO1PR11MB5169:EE_|BL1PR11MB5556:EE_
x-ms-office365-filtering-correlation-id: c6315cf6-9cbe-41c2-57eb-08db354511af
x-ms-exchange-senderadcheck: 1
x-ms-exchange-antispam-relay: 0
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: rK+RyUqfq+gdY3cR32KeS9r9ouE7FWGpJru2VBk0M9b7tJOG20Gxa3U18kK/kzfRiBuPblA4V7z5PRCkFHqtBUQciqw4yQ9t3BS0xJ1XsvQv/TLzLYhlThKMdy6tEITT7vUrPLiZh5fFf8/1bZJ8tTaeibZsxqEpEm7XyRE8zkzHOGjj9woPLuzNbRB22rpMqRKk4NE1ZkfA0JVSxaAlqzL6HJKmf6Lr7p+QX0U3vE9QPboNBCUS1TUWx3Dic7qg93r23O/fxzbq6izdmLK0D0AeR8I6SBBg5/eU4Mc5xKSR8N4td9zxMKvm+1/0/V/ItD1PEXLzhjOfw3HtJk4I/cRgUYeZMdzJZXFaAu8cNB6A8PYbJwAUtxEslT9WpQ8oXQwTQ68+WeDpoMI+eos4bRyZV6qSrb+CnOZJIUl1seGREGwd02DlTzkHmzvGNRK6u0L0ohf7zsb1MLyOWUvvkrKm1wWIjDWXo7F6pH6m4yvYUEqzqsv4ABsa5hLrMXCPZ5nTWJHfbKu+WOs2qhCzCHLW/Ru4fEvAi3BisnkU4ltPka6CfYtfipSdLP2fvbRgiICgJQN+nlLvQ/DPIbMjtxAvL+gHgtKWpWjX/Q1hUotZkHaK8gr15vCtaWnAtDXTAUF0snrSHtfiCmdzQpTLQrAYpNiPo8gKUJYoU5fL5Sw=
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CO1PR11MB5169.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(346002)(136003)(366004)(39860400002)(376002)(396003)(451199021)(33656002)(21615005)(2616005)(6486002)(122000001)(54906003)(2906002)(83380400001)(82960400001)(478600001)(66574015)(5660300002)(166002)(30864003)(38070700005)(41300700001)(71200400001)(8936002)(38100700002)(66446008)(6512007)(64756008)(76116006)(91956017)(66476007)(8676002)(86362001)(66556008)(6916009)(66946007)(6506007)(4326008)(53546011)(316002)(26005)(966005)(186003)(36756003)(45980500001)(579004); DIR:OUT; SFP:1102;
x-ms-exchange-antispam-messagedata-chunkcount: 1
x-ms-exchange-antispam-messagedata-0: uNp76DBptIelfbtjhVtrx5GCDUEAE/kDt71DNScqDvbOVXcqx60AyyuULBq/yD0Aorc6/GOdQwV98rQeAHx7T/X7g7dtt3eNctoJbQ0FNMj5oZFAPE70Xpq2TAYgydB2kFHwkzTtZAAXZFy74LwrMAY/EBhdV34ocJEo8rdgsOIt3jF8iQdHPMoGnU+ZeW97OlKf2TJ/tgrQP4RPsdLDC0pU43qEow1neZgWl6e/oedF3j7HAVAPvJlLZ10fSF+lJ6r2xO16P1n9Fio4nmX3w1XR5juhm1vcy1t1jLhsyGg3fyMEFkNeezlOGvp+rQdNIqiWHXxAoYzOYXKpfanNFdLJ1uthjqIsdclbdls/3LQinv+4XipC4MJOtCtZkrhCln2EHBFfsN5xwqHLDe9I5/3F9QyHi4bo6IA+JE4GFddz6TIQ3FYBmaQr05Q5wlDSabgc5kRPRiDr06cvPAcuUyGD1dp95WUXVjdzm8TMSCAZiQD1gb41zxWKZ94YXRiGui1iunVgBWh/3sqWaX24Oj0XSWd5EmpBMn7uf5uC4x62KRCG0z9dOmLuolq9oe2hNK1isN0laUjrTr5f64oX40kFIbb9XbpoKc/WAa0f7+whGicR0w6ohjYEydrIlINXQz2UGXyS2NV1VadLx118jrZxMksO19DJp5FF8WBBKRFHxro0raOPlgl9vXgxyQckSxAK08KTx1zPWK4aNviHJ6iB1ZOppsUAsS7/d4b81315LokTi9dXCPmC7vOOlrCC16W/zBgpQ1zUVoQ1ayi1JUVU6CM0sB4X2yoTr0pPnkGpSfaLhf7beGnXL3OIzAKXUhD4dwbrzdkj4SeTLv7wCz+0R+pxePuwfOOytef4zE2RIn8FTbdDIM8Yroe7fMyfrV95nGckoW2NKnUqe1/Xp0Ph+D0QFPHlNStZUOc6QUJGPKB+fhvVdd82S0je3PYusVImcObDAF3GWADCWq2m/f4aeYIR/dsRmzVmkp5CQkoDc6A4Yh1mStUGSHhDK40E+PvRx+hc4jMdDYCaPFKd0COG7fBU8CW8isLCwgc6/nwZ32BxMWQ6Xs0spIp+VCpYCjqBn6z7BG8WB4crm70XMVS40YTyVv2vtLAkrhdKlrkyky8DYHywG4hjMIiadsXwVRPcv974qw9mL/hZqiBfbr9feBuDSGck0MTXhDTRjJA9ejOxqsraNp8q2nAYh1Pkkt/a1954BbPJxXL1Rc+UTC285gVDN4TYYybMJN+rhO8LU5WQeE0k6qcZGm8zzUldS2z/+xRiLQYEzfZ+tZIHCE9tXo4EJNTPJSOHKECnZmIBaa4eox7yj6v9FtToGQgcWc82A/kOF7DunnVKaDEgHztxmv/AOQ4Uj7Em+9Q9QWetMg66WOuw75Kg+mjrzBKUs9qPeq0xhmj5TftzQmcAXcJH4lVV3sN11e+T0Oby5pW84GRQoc9Jv8trAo8FmPBcNKE85qV5CHLluaz6QRneZxGkBZIZ0lndQpGQmsUAQknEXji7/XPnySXtsPDlXuSY6QPkyzTxO4c9cKWDlBJu6KOu+qhDBRHa5Wfqtt4XksOv/6kp/ci6oic8m+4n9YWP
Content-Type: multipart/alternative; boundary="_000_CB59784A7B7447298055B1334D1042BEintelcom_"
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: CO1PR11MB5169.namprd11.prod.outlook.com
X-MS-Exchange-CrossTenant-Network-Message-Id: c6315cf6-9cbe-41c2-57eb-08db354511af
X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Apr 2023 19:44:56.8455 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: dvEzkeBqIGgyCLEq8MJfRky314crsXQkIllqKMYPZxSXYgIQ5q41Z9MaWQvcaGJoFU40SqItvpwc41HmohqECA==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL1PR11MB5556
X-OriginatorOrg: intel.com
Archived-At: <https://mailarchive.ietf.org/arch/msg/rats/9-2ni_0kHrYZjGGES8E791ajED8>
Subject: Re: [Rats] [COSE] [Anima] cose+cbor vs cwt in MIME types
X-BeenThere: rats@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Remote ATtestation procedureS <rats.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rats>, <mailto:rats-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/rats/>
List-Post: <mailto:rats@ietf.org>
List-Help: <mailto:rats-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rats>, <mailto:rats-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 04 Apr 2023 19:45:57 -0000

> As I mentioned before, the multiple suffixes draft might not land... So it would be better to avoid multiple plus
I was following your lead from earlier in the thread.

From: Orie Steele <orie@transmute.industries>
Date: Monday, April 3, 2023 at 5:09 PM
To: "Smith, Ned" <ned.smith@intel.com>
Cc: Laurence Lundblade <lgl@island-resort.com>, Esko Dijk <esko.dijk@iotconsultancy.nl>, Michael Richardson <mcr@sandelman.ca>, Thomas Fossati <Thomas.Fossati@arm.com>, Thomas Fossati <tho.ietf@gmail.com>, cose <cose@ietf.org>, rats <rats@ietf.org>, "anima@ietf.org" <anima@ietf.org>
Subject: Re: [COSE] [Rats] [Anima] cose+cbor vs cwt in MIME types

Per the JWT BCP, regarding typ.

https://datatracker.ietf.org/doc/html/rfc8725#name-use-explicit-typing

The +jwt suffix goes on the end.

You would need to register +eat as a structured suffix otherwise.

My understanding is that you currently intend to register application/eat as a subtype, not a structured suffix (you can do both, see json).

The 116 meeting mentions that while it is the case today that most structured suffix are also registered subtypes, this might not be a reliable assumption in the future.

The current multiple suffixes draft makes it clear that processing of suffixes is right to left (confusing / surprising perhaps).

So you can read the subtype "eat" and then consider it as +cwt, +cose, +cbor, for an example media type of "application/eat+cbor+cose+cwt"

As I mentioned before, the multiple suffixes draft might not land... So it would be better to avoid multiple plus and follow the conventions from the JWT BCP, and avoid registering new or interesting suffixes, given the current confusion regarding them.

I'm not saying any of this is correct, just noting what the suffixes draft says today, and how it is related to the several +jwt media types that have already been registered.

Another interesting case to consider... Data URI of type "eat+jwt+gzip"... Since base64 URL encoding can quickly max out QR Codes / NFC or URL limits.

Decompress, verify, parse / validate.

OS


On Mon, Apr 3, 2023, 6:36 PM Smith, Ned <ned.smith@intel.com<mailto:ned.smith@intel.com>> wrote:
> application/eat+cbor+cose+cwt

EAT is a specialization of a CWT or a JWT. What in eat is encoded before the cbor (which encodes the token)?

If the conceptual message is identified by a message wrapper draft-ftbs-rats-msg-wrap-02 - RATS Conceptual Messages Wrapper (ietf.org)<https://datatracker.ietf.org/doc/draft-ftbs-rats-msg-wrap/>, then the cbor bytes could be encoded in an cmw array. As in:
`[ “application/cbor+cose+cwt+eat”, bstr ]`

The discussion around cmw hasn’t concluded, but in theory, the array structure could be embedded in a conveyance protocol or message that would have some way to identify it as a cmw. The cmw I-D doesn’t try to define a media type name for `cmw-array`. Hopefully, that isn’t needed. But it is the outer most onion skin before talking about conveyance protocol / message framing.

-Ned

From: Orie Steele <orie@transmute.industries>
Date: Monday, April 3, 2023 at 3:21 PM
To: "Smith, Ned" <ned.smith@intel.com<mailto:ned.smith@intel.com>>
Cc: Laurence Lundblade <lgl@island-resort.com<mailto:lgl@island-resort.com>>, Esko Dijk <esko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl>>, Michael Richardson <mcr@sandelman.ca<mailto:mcr@sandelman.ca>>, Thomas Fossati <Thomas.Fossati@arm.com<mailto:Thomas.Fossati@arm.com>>, Thomas Fossati <tho.ietf@gmail.com<mailto:tho.ietf@gmail.com>>, "cose@ietf.org<mailto:cose@ietf.org>" <cose@ietf.org<mailto:cose@ietf.org>>, "rats@ietf.org<mailto:rats@ietf.org>" <rats@ietf.org<mailto:rats@ietf.org>>, "anima@ietf.org<mailto:anima@ietf.org>" <anima@ietf.org<mailto:anima@ietf.org>>
Subject: Re: [COSE] [Rats] [Anima] cose+cbor vs cwt in MIME types

Inline:

On Mon, Apr 3, 2023 at 3:10 PM Smith, Ned <ned.smith@intel.com<mailto:ned.smith@intel.com>> wrote:
> there’s no standard for the key material and key identification
The observation is that the COSE block contains a key-id that can be used to locate the key material (e.g., I assume key material refers to the public key needed to verify the COSE signature given asymmetric crypto). The COSE parser (layer) would normally be equipped to handle this sort of thing. If the media type was ‘cwt’ the parser would have to support everything in the COSE layer as well as what’s in the token part as well. EAT adds additional parsing requirements on top of CWT.  Hence, the expression “application/cbor+cose+cwt+eat” isn’t unreasonable.

I would expect something more like this (according the current suffixes draft):
application/eat+cbor+cose+cwt

or simply:

application/eat+cwt (since cwt implies cbor + cose)

Closest JWT analogy currently in the registry:

- https://www.iana.org/assignments/media-types/application/at+jwt
- https://www.rfc-editor.org/rfc/rfc9068.html

keep in mind the multiple suffixes is not yet an RFC... if you can avoid multiple suffixes, I think it is very wise to do so.

The reason to use multiple suffixes is to signal that there is meaningful processing that can be done... for token formats, I feel this is less true than json flavors, such as "application/vc+ld+json".

I had a discussion with friends at IETF 116 about "sd+jwt" vs "sd-jwt", related to https://www.ietf.org/archive/id/draft-ietf-oauth-selective-disclosure-jwt-03.html#name-iana-considerations-24

For example, sd-jwt implies normal jwt processing is not meaningful, whereas sd+jwt implies jwt processing is meaningful... There were good arguments on both sides.
Given the current state of consensus on multiple suffixes, I would potentially avoid taking a dependency on it if possible, sticking to just 1 plus.

Someone could argue that “…+cose+cwt…” doesn’t add anything, as “+cwt” alone could infer both. The same is true for “…cbor+eat…”.
But I think there is value in being able to describe a fully qualified representation that is the primitive representation after the various inferred representations have been computed.

> but that’s about the library, not dispatching some content arriving to a particular application
I think the value is it doesn’t assume monolithic applications. A library or processor that is specific to the encoding between the pluses, e.g., “+cose+”, can be used in some sort of highly optimized pipeline, rather than presumed to be a monolith.

From: Laurence Lundblade <lgl@island-resort.com<mailto:lgl@island-resort.com>>
Date: Monday, April 3, 2023 at 12:44 PM
To: Orie Steele <orie@transmute.industries>
Cc: "Smith, Ned" <ned.smith@intel.com<mailto:ned.smith@intel.com>>, Esko Dijk <esko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl>>, Michael Richardson <mcr@sandelman.ca<mailto:mcr@sandelman.ca>>, Thomas Fossati <Thomas.Fossati@arm.com<mailto:Thomas.Fossati@arm.com>>, Thomas Fossati <tho.ietf@gmail.com<mailto:tho.ietf@gmail.com>>, "cose@ietf.org<mailto:cose@ietf.org>" <cose@ietf.org<mailto:cose@ietf.org>>, "rats@ietf.org<mailto:rats@ietf.org>" <rats@ietf.org<mailto:rats@ietf.org>>, "anima@ietf.org<mailto:anima@ietf.org>" <anima@ietf.org<mailto:anima@ietf.org>>
Subject: Re: [COSE] [Rats] [Anima] cose+cbor vs cwt in MIME types

I’m not sure identifying something as COSE, or even CWT is that useful because there’s no standard for the key material and key identification that cuts across all uses of COSE or CWT.

For example with EAT the receiver probably will need an endorsement (a very specific thing with very specific semantics) with a public key to be able to process the CWT/COSE. If COSE is used for encrypted email (a future S/MIME), the key material identification will probably be really different. It’s hard for me to see what a generic COSE/CWT handler is going to do here. It’s good and well if an EAT processor uses the same COSE library as an S/MIME processor, but that’s about the library, not dispatching some content arriving to a particular application.

No objection to the work here. Just some observations.

LL



On Apr 3, 2023, at 11:14 AM, Orie Steele <orie@transmute.industries<mailto:orie@transmute.industries>> wrote:

Yes! That seems to have been one proposal, related to cleaning up the registry and clarifying interpretation.

If you have strong opinions on this, please help contribute to the dialog on this media types list:

https://mailarchive.ietf.org/arch/msg/media-types/qO72m31whV5QZmV6kj55KDqS8n8/

Regards,

OS

On Mon, Apr 3, 2023 at 1:12 PM Smith, Ned <ned.smith@intel.com<mailto:ned.smith@intel.com>> wrote:
Interesting!
It would be nice if I-D.ietf-mediaman-suffixes could define a backward compatibility convention that shows how existing / registered media-type-names can co-exist with I-D.ietf-mediaman-suffixes.


From: Orie Steele <orie@transmute.industries<mailto:orie@transmute.industries>>
Date: Monday, April 3, 2023 at 10:47 AM
To: "Smith, Ned" <ned.smith@intel.com<mailto:ned.smith@intel.com>>
Cc: Esko Dijk <esko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl>>, Michael Richardson <mcr@sandelman.ca<mailto:mcr@sandelman.ca>>, Thomas Fossati <Thomas.Fossati@arm.com<mailto:Thomas.Fossati@arm.com>>, Thomas Fossati <tho.ietf@gmail.com<mailto:tho.ietf@gmail.com>>, "cose@ietf.org<mailto:cose@ietf.org>" <cose@ietf.org<mailto:cose@ietf.org>>, "rats@ietf.org<mailto:rats@ietf.org>" <rats@ietf.org<mailto:rats@ietf.org>>, "anima@ietf.org<mailto:anima@ietf.org>" <anima@ietf.org<mailto:anima@ietf.org>>
Subject: Re: [COSE] [Rats] [Anima] cose+cbor vs cwt in MIME types

At IETF 116 this draft was discussed:

- https://datatracker.ietf.org/doc/draft-ietf-mediaman-suffixes<https://datatracker.ietf.org/doc/draft-ietf-mediaman-suffixes/>
- https://youtu.be/BrP1upACJ0c?t=1744

TLDR; there is work in progress to define multiple suffixes, and how they are interpreted.

This would be relevant to potential future +cwt media types, it is already causing us some concern with respect to special cases of +jwt.

Regards,

OS

On Mon, Apr 3, 2023 at 12:28 PM Smith, Ned <ned.smith@intel.com<mailto:ned.smith@intel.com>> wrote:
It seems the early registrations focused on encoding formats for content to the right of the "+" like '+xml', '+json', '+cbor', '+der', while later registrations seem to include schema formats like '+jwt', '+sqlite3', and '+tlv'.

It would have been nice if the registry defined the right side for encoding formats and let the left side contain content / schema formats IMHO. That way, the parsers could scan for the "+" to identify if it supports the encoding format as a first pass operation. If it can't decode the first byte, then there's no point in going further.

If it can decode, then the first byte/bytes may provide insight into what content is there. For example, a CBOR tagged structure. But additionally, the left hand side identifies schemas. Given many data structures can be integrity protected, signed, and encrypted. Supplying a value that describes a cryptographic enveloping schema / format seems like a reasonable requirement for the '-label' to the immediate left of the plus, e.g., "-cose+cbor".
The data within the cryptographic envelope may follow a well-defined schema such as the RATS ar4si. E.g., "ar4si-cose+cbor". I don't see a problem with omitting the cryptographic envelope label if no envelope is provided. E.g., "ar4si-+cbor".

JWT and CWT are both an envelope and a data model schema, so the cryptographic envelope could be inferred. But it wouldn't be incorrect to restate the obvious for the benefit of the parsers who only care about cryptographic wrapper processing. E.g., "jwt-jose+json" is still a reasonable way to encode 'jwt'.

If there are content schemas that are to the left of some other content schema, then that can be accommodate easily by prepending another 'label-'. E.g., "ar4si-jwt-jose+json".

This approach allows an initial parser / message router to get a view of all the parsers needed to fully inspect the message in advance of making an initial message routing decision which would enable efficient parser offload architectures. There could be different registries for the different types of structure "+label" for encoding formats only, "-label" to the immediate left of "+" for cryptographic enveloping, and application formats for the next left most content.

To make processing even more efficient, the content-type-name should reverse the order based on outer-most format. E.g., "json+jose-jwt-ar4si". This way buffer only needs to contain the first bytes up to the '+' and so forth.

I realize this goes beyond the initial focus of the discussion thread. But IETF is also concerned about the long-term future of the Internet and in optimizing wherever it makes sense. Content typing is just a form of deep packet inspection that goes beyond network framing.

Cheers,
Ned

On 4/3/23, 12:33 AM, "RATS on behalf of Esko Dijk" <rats-bounces@ietf.org<mailto:rats-bounces@ietf.org> <mailto:rats-bounces@ietf.org<mailto:rats-bounces@ietf.org>> on behalf ofesko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl> <mailto:esko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl>>> wrote:


Hi,


As for the questions mentioned on these slides:


1. "Is is '-cose+cbor' or '-cbor+cose'


The registry https://www.iana.org/assignments/media-type-structured-suffix/media-type-structured-suffix.xhtml<https://www.iana.org/assignments/media-type-structured-suffix/media-type-structured-suffix.xhtml> lists the subtypes that one have after the '+' sign.
'cbor' is there but 'cose' is not. 'cwt' is also not there.


So for the moment, registering a 'mytype+cose' or 'voucher+cose' or 'voucher-cbor+cose' is not possible now unless you would also register the '+cose' as a subtype. RFC 9052 did not choose to register the subtype '+cose', for whatever reason.


Luckily because COSE is just "plain CBOR" itself , we can use the subtype '+cbor'. So having "voucher-cose+cbor" would be fine. Also "voucher+cbor" would be equally ok albeit a little bit less informative that it contains COSE.




2. "are they sufficiently different" (this is about application/voucher-cose+cbor and application/eat+cwt formats)


The voucher is not a CWT format, e.g. it does not use the standardized CWT claims at all. It defines an own format within the constraints of YANG CBOR, while CWT does not use any YANG semantics.


(Now converting the constrained Voucher format into a CWT based format would certainly be possible; but that's probably not the discussion intended by these slides.)


Regards
Esko


PS more detailed info at
https://github.com/anima-wg/constrained-voucher/issues/264 <https://github.com/anima-wg/constrained-voucher/issues/264>
https://github.com/anima-wg/constrained-voucher/issues/263 <https://github.com/anima-wg/constrained-voucher/issues/263>


-----Original Message-----
From: Anima <anima-bounces@ietf.org<mailto:anima-bounces@ietf.org> <mailto:anima-bounces@ietf.org<mailto:anima-bounces@ietf.org>>> On Behalf Of Michael Richardson
Sent: Monday, March 27, 2023 01:19
To: Thomas Fossati <Thomas.Fossati@arm.com<mailto:Thomas.Fossati@arm.com> <mailto:Thomas.Fossati@arm.com<mailto:Thomas.Fossati@arm.com>>>; Thomas Fossati <tho.ietf@gmail.com<mailto:tho.ietf@gmail.com><mailto:tho.ietf@gmail.com<mailto:tho.ietf@gmail.com>>>; cose@ietf.org<mailto:cose@ietf.org> <mailto:cose@ietf.org<mailto:cose@ietf.org>>; rats@ietf.org<mailto:rats@ietf.org> <mailto:rats@ietf.org<mailto:rats@ietf.org>>; anima@ietf.org<mailto:anima@ietf.org><mailto:anima@ietf.org<mailto:anima@ietf.org>>
Subject: Re: [Anima] [Rats] cose+cbor vs cwt in MIME types


Michael Richardson <mcr+ietf@sandelman.ca<mailto:mcr%2Bietf@sandelman.ca> <mailto:mcr+ietf@sandelman.ca<mailto:mcr%2Bietf@sandelman.ca>>> wrote:
> COSE CHAIRS: can we have 5 minutes for this discussion?
> I guess I can make two slides tomorrow and get Thomas to co-author them.


I guess we didn't get any time at COSE.


https://github.com/anima-wg/voucher/blob/main/presentations/ietf116-cose-mime-cwt.pdf <https://github.com/anima-wg/voucher/blob/main/presentations/ietf116-cose-mime-cwt.pdf>


_______________________________________________
Anima mailing list
Anima@ietf.org<mailto:Anima@ietf.org> <mailto:Anima@ietf.org<mailto:Anima@ietf.org>>
https://www.ietf.org/mailman/listinfo/anima <https://www.ietf.org/mailman/listinfo/anima>


_______________________________________________
RATS mailing list
RATS@ietf.org<mailto:RATS@ietf.org> <mailto:RATS@ietf.org<mailto:RATS@ietf.org>>
https://www.ietf.org/mailman/listinfo/rats <https://www.ietf.org/mailman/listinfo/rats>



_______________________________________________
COSE mailing list
COSE@ietf.org<mailto:COSE@ietf.org>
https://www.ietf.org/mailman/listinfo/cose


--
ORIE STEELE
Chief Technical Officer
www.transmute.industries<http://www.transmute.industries>

Error! Filename not specified.<https://www.transmute.industries/>


--
ORIE STEELE
Chief Technical Officer
www.transmute.industries<http://www.transmute.industries/>

Error! Filename not specified.<https://www.transmute.industries/>
_______________________________________________
COSE mailing list
COSE@ietf.org<mailto:COSE@ietf.org>
https://www.ietf.org/mailman/listinfo/cose



--
ORIE STEELE
Chief Technical Officer
www.transmute.industries

Error! Filename not specified.<https://www.transmute.industries/>