Skip to main content

CBOR Web Token (CWT) Claims in COSE Headers
draft-ietf-cose-cwt-claims-in-headers-04

The information below is for an old version of the document.
Document Type
This is an older version of an Internet-Draft whose latest revision state is "Active".
Authors Tobias Looker , Michael B. Jones
Last updated 2023-04-24 (Latest revision 2023-03-12)
RFC stream Internet Engineering Task Force (IETF)
Formats
Reviews
Additional resources Mailing list discussion
Stream WG state WG Document
Document shepherd (None)
IESG IESG state I-D Exists
Consensus boilerplate Unknown
Telechat date (None)
Responsible AD (None)
Send notices to (None)
draft-ietf-cose-cwt-claims-in-headers-04
COSE                                                           T. Looker
Internet-Draft                                                     Mattr
Intended status: Standards Track                                M. Jones
Expires: 26 October 2023                                      individual
                                                           24 April 2023

              CBOR Web Token (CWT) Claims in COSE Headers
                draft-ietf-cose-cwt-claims-in-headers-04

Abstract

   This document describes how to include CBOR Web Token (CWT) claims in
   the header parameters of any COSE structure.  This functionality
   helps to facilitate applications that wish to make use of CBOR Web
   Token (CWT) claims in encrypted COSE structures and/or COSE
   structures featuring detached signatures, while having some of those
   claims be available before decryption and/or without inspecting the
   detached payload.

Discussion Venues

   This note is to be removed before publishing as an RFC.

   Source for this draft and an issue tracker can be found at
   https://github.com/tplooker/draft-ietf-cose-cwt-claims-in-headers.

Status of This Memo

   This Internet-Draft is submitted in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at https://datatracker.ietf.org/drafts/current/.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   This Internet-Draft will expire on 26 October 2023.

Copyright Notice

   Copyright (c) 2023 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

Looker & Jones           Expires 26 October 2023                [Page 1]
Internet-Draft  CBOR Web Token (CWT) Claims in COSE Head      April 2023

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents (https://trustee.ietf.org/
   license-info) in effect on the date of publication of this document.
   Please review these documents carefully, as they describe your rights
   and restrictions with respect to this document.  Code Components
   extracted from this document must include Revised BSD License text as
   described in Section 4.e of the Trust Legal Provisions and are
   provided without warranty as described in the Revised BSD License.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
     1.1.  Requirements Terminology  . . . . . . . . . . . . . . . .   3
   2.  Representation  . . . . . . . . . . . . . . . . . . . . . . .   3
   3.  Privacy Considerations  . . . . . . . . . . . . . . . . . . .   3
   4.  Security Considerations . . . . . . . . . . . . . . . . . . .   4
   5.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   4
   6.  Normative References  . . . . . . . . . . . . . . . . . . . .   4
   7.  Informative References  . . . . . . . . . . . . . . . . . . .   4
   Appendix A.  Document History . . . . . . . . . . . . . . . . . .   5
   Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .   5

1.  Introduction

   In some applications of COSE, it is useful to have a standard
   representation of CWT claims [RFC8392] available in the header
   parameters.  These include encrypted COSE structures, which may or
   may not be an encrypted CWT and/or those featuring a detached
   signature.

   Section 5.3 of the JWT RFC [RFC7519] defined a similar mechanism for
   expressing selected JWT based claims as JOSE header parameters.  This
   JWT feature was motivated by the desire to have certain claims, such
   as the Issuer value, be visible to software processing the JWT, even
   though the JWT is encrypted.  No corresponding feature was
   standardized for CWTs, which was an omission that this specification
   corrects.

   Directly including CWT claim values as COSE header parameter values
   would not work, since there are conflicts between the numeric header
   parameter assignments and the numeric CWT claim assignments.
   Instead, this specification defines a single header parameter
   registered in the IANA "COSE Header Parameters" registry that creates
   a location to store CWT claims in a COSE header parameter.

Looker & Jones           Expires 26 October 2023                [Page 2]
Internet-Draft  CBOR Web Token (CWT) Claims in COSE Head      April 2023

1.1.  Requirements Terminology

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
   "OPTIONAL" in this document are to be interpreted as described in BCP
   14 [RFC2119] [RFC8174] when, and only when, they appear in all
   capitals, as shown here.

2.  Representation

   This document defines the following COSE header parameter:

     +========+================+=======+============+===============+
     | Name   | Label          | Value | Value      | Description   |
     |        |                | Type  | Registry   |               |
     +========+================+=======+============+===============+
     | CWT    | TBD (requested | map   | [IANA.CWT] | location for  |
     | claims | assignment 11) |       |            | CWT claims in |
     |        |                |       |            | COSE headers  |
     +--------+----------------+-------+------------+---------------+

                                 Table 1

   The following is a non-normative description for the value type of
   the CWT claim header parameter using CDDL [RFC8610].

   CWT-Claims = {
    * Claim-Label => any
   }

   Claim-Label = int / text

   It is RECOMMENDED that the CWT claims header parameter is used only
   in a protected header to avoid the contents being malleable.  The
   header parameter MUST only occur once in either the protected or
   unprotected header of a COSE structure.

3.  Privacy Considerations

   Some of the registered CWT claims may contain privacy-sensitive
   information.  Therefore care must be taken when expressing CWT claims
   in COSE headers.

Looker & Jones           Expires 26 October 2023                [Page 3]
Internet-Draft  CBOR Web Token (CWT) Claims in COSE Head      April 2023

4.  Security Considerations

   In cases where CWT claims are both present in the payload and the
   header, an application receiving such a structure MUST verify that
   their values are identical, unless the application defines other
   specific processing rules for these claims.

   Implementers should also review the security considerations for CWT,
   which are documented in Section 8 of [RFC8392].

5.  IANA Considerations

   IANA is requested to register the new COSE Header parameter in the
   table in Section 2 in the "COSE Header Parameters" registry
   [IANA.COSE].

6.  Normative References

   [IANA.COSE]
              IANA, "COSE Header Parameters",
              <https://www.iana.org/assignments/cose/cose.xhtml#header-
              parameters>.

   [IANA.CWT] IANA, "CBOR Web Token (CWT) Claims",
              <https://www.iana.org/assignments/cwt/cwt.xhtml>.

7.  Informative References

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119,
              DOI 10.17487/RFC2119, March 1997,
              <https://www.rfc-editor.org/info/rfc2119>.

   [RFC7519]  Jones, M., Bradley, J., and N. Sakimura, "JSON Web Token
              (JWT)", RFC 7519, DOI 10.17487/RFC7519, May 2015,
              <https://www.rfc-editor.org/info/rfc7519>.

   [RFC8174]  Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
              2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
              May 2017, <https://www.rfc-editor.org/info/rfc8174>.

   [RFC8392]  Jones, M., Wahlstroem, E., Erdtman, S., and H. Tschofenig,
              "CBOR Web Token (CWT)", RFC 8392, DOI 10.17487/RFC8392,
              May 2018, <https://www.rfc-editor.org/info/rfc8392>.

Looker & Jones           Expires 26 October 2023                [Page 4]
Internet-Draft  CBOR Web Token (CWT) Claims in COSE Head      April 2023

   [RFC8610]  Birkholz, H., Vigano, C., and C. Bormann, "Concise Data
              Definition Language (CDDL): A Notational Convention to
              Express Concise Binary Object Representation (CBOR) and
              JSON Data Structures", RFC 8610, DOI 10.17487/RFC8610,
              June 2019, <https://www.rfc-editor.org/info/rfc8610>.

Appendix A.  Document History

   -04

   *  Update author affiliation.

   *  Add standard reference to RFC terminology.

   *  Added reference to security considerations from RFC8392.

   -03

   *  Added recommendation around header treatment in protected vs
      unprotected.

   -02

   *  Added CDDL description for CWT claim value.

   -01

   *  Changed example from Key ID to Issuer.

   -00

   *  Created draft-ietf-cose-cwt-claims-in-headers-00 from draft-
      looker-cose-cwt-claims-in-headers-00 following working group
      adoption.

Authors' Addresses

   Tobias Looker
   Mattr
   Email: tobias.looker@mattr.global

   Michael B. Jones
   individual
   Email: michael_b_jones@hotmail.com
   URI:   https://self-issued.info/

Looker & Jones           Expires 26 October 2023                [Page 5]