One document matched: draft-ietf-jose-json-web-key-02.xml


<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<?xml-stylesheet type='text/xsl' href='http://xml.resource.org/authoring/rfc2629.xslt' ?>

<?rfc toc="yes"?>
<?rfc tocompact="yes"?>
<?rfc tocdepth="4"?>
<?rfc tocindent="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>

<rfc category="std" ipr="trust200902" docName="draft-ietf-jose-json-web-key-02">

  <front>
    <title abbrev="JWK">JSON Web Key (JWK)</title>

    <author fullname="Michael B. Jones" initials="M.B." surname="Jones">
      <organization>Microsoft</organization>
      <address>
        <email>mbj@microsoft.com</email>
        <uri>http://self-issued.info/</uri>
      </address>
    </author>

    <date day="12" month="May" year="2012" />

    <area>Security</area>
    <workgroup>JOSE Working Group</workgroup>

    <keyword>RFC</keyword>
    <keyword>Request for Comments</keyword>
    <keyword>I-D</keyword>
    <keyword>Internet-Draft</keyword>
    <keyword>JavaScript Object Notation</keyword>
    <keyword>JSON</keyword>
    <keyword>JSON Web Token</keyword>
    <keyword>JWT</keyword>
    <keyword>JSON Web Signature</keyword>
    <keyword>JWS</keyword>
    <keyword>JSON Web Encryption</keyword>
    <keyword>JWE</keyword>
    <keyword>JSON Web Key</keyword>
    <keyword>JWK</keyword>

    <abstract>
      <t>
	A JSON Web Key (JWK) is a JSON data structure that represents
	a public key.
	This specification also defines a JSON Web Key Set (JWK Set)
	JSON data structure for representing a set of JWKs.
	Cryptographic algorithms and identifiers used with this
	specification are enumerated in the separate
	JSON Web Algorithms (JWA) specification.
      </t>
    </abstract>

    <note title="Requirements Language">
      <t>
	The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
	NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and
	"OPTIONAL" in this document are to be interpreted as described
	in <xref target="RFC2119">RFC 2119</xref>.
      </t>
    </note>
  </front>

  <middle>
    <section title="Introduction">
      <t>
	A JSON Web Key (JWK) is a JSON data structure that represents
	a public key as a JSON object <xref
	target="RFC4627" />.
	This specification also defines a JSON Web Key Set (JWK Set)
	JSON data structure for representing a set of JWKs.
	Cryptographic algorithms and identifiers used with this
	specification are enumerated in the separate
	JSON Web Algorithms (JWA) <xref target="JWA" /> specification.
      </t>
      <t>
	Non-goals for this specification include representing
	private keys, representing symmetric keys, representing
	certificate chains, representing certified keys, and replacing
	X.509 certificates.
      </t>
      <t>
	JWKs are used in the
	JSON Web Signature (JWS) <xref target="JWS" />
	<spanx style="verb">jwk</spanx> (JSON Web Key)
	header parameter and the
	JSON Web Encryption (JWE) <xref target="JWE" />
	<spanx style="verb">jwk</spanx> (JSON Web Key) and
	<spanx style="verb">epk</spanx> (Ephemeral Public Key)
	header parameters.
	The resources referenced by the
	JWS
	<spanx style="verb">jku</spanx> (JWK Set URL) and
	JWE
	<spanx style="verb">jku</spanx> (JWK Set URL)
	header parameters contain JWK Sets.
      </t>
    </section>

    <section title="Terminology">
      <t>
	<list style="hanging">

          <t hangText="JSON Web Key (JWK)">
	    A JSON data structure that represents a public key.
	  </t>
	  <t hangText="JSON Web Key Set (JWK Set)">
	    A JSON object that contains an array of JWKs as a member.
	  </t>
          <t hangText="Base64url Encoding">
	    For the purposes of this specification, this term always
	    refers to the URL- and filename-safe Base64 encoding
	    described in <xref target="RFC4648">RFC 4648</xref>,
	    Section 5, with the (non URL-safe) '=' padding characters
	    omitted, as permitted by Section 3.2.  (See Appendix B of
	    <xref target="JWS" /> for notes on implementing base64url
	    encoding without padding.)
	  </t>
        </list>
      </t>
    </section>

    <section title="Example JSON Web Key Set" anchor="ExampleJWKSet">

      <t>
	The following example JWK Set contains two public keys
	represented as JWKs: one
	using an Elliptic Curve algorithm and a second one using an
	RSA algorithm.  The first specifies that the key is to be
	used for encryption.  Both provide a Key ID for key matching
	purposes.  In both cases, integers are represented using the
	base64url encoding of their big endian representations.
	(Long lines are broken are for display purposes only.)
      </t>

      <figure><artwork><![CDATA[{"keys":
  [
    {"alg":"EC",
     "crv":"P-256",
     "x":"MKBCTNIcKUSDii11ySs3526iDZ8AiTo7Tu6KPAqv7D4",
     "y":"4Etl6SRW2YiLUrN5vfvVHuhp7x8PxltmWWlbbM4IFyM",
     "use":"enc",
     "kid":"1"},
 
    {"alg":"RSA",
     "mod": "0vx7agoebGcQSuuPiLJXZptN9nndrQmbXEps2aiAFbWhM78LhWx
4cbbfAAtVT86zwu1RK7aPFFxuhDR1L6tSoc_BJECPebWKRXjBZCiFV4n3oknjhMs
tn64tZ_2W-5JsGY4Hc5n9yBXArwl93lqt7_RN5w6Cf0h4QyQ5v-65YGjQR0_FDW2
QvzqY368QQMicAtaSqzs8KJZgnYb9c7d0zgdAZHzu6qMQvRL5hajrn1n91CbOpbI
SD08qNLyrdkt-bFTWhAI4vMQFh6WeZu0fM4lFd2NcRwr3XPksINHaQ-G_xBniIqb
w0Ls1jF44-csFCur-kEgU8awapJzKnqDKgw",
     "exp":"AQAB",
     "kid":"2011-04-29"}
  ]
}]]></artwork></figure>

    </section>

    <section title="JSON Web Key (JWK) Format">
      <t>
	A JSON Web Key (JWK) is a JSON object containing specific
	members, as specified below.  Those members that are common
	to all key types are defined below.
      </t>
      <t>
	JWKs also require members that are specific to the particular
	key algorithm family to represent the key parameters.
	These algorithm specific members are defined in Section 5 of the
	JSON Web Algorithms (JWA) <xref target="JWA" /> specification.
      </t>
      <t>
	The member names within a JWK MUST be unique;
	objects with duplicate member names MUST be rejected.
      </t>
      <t>
	Additional members MAY be present in the JWK.
	If present, they MUST be understood by implementations using them.
	Parameters for representing keys for additional
	algorithm families or additional key properties
	SHOULD either be defined in the IANA JSON Web Key Parameters registry
	<xref target="JWA" /> or be
	a URI that contains a collision resistant namespace.
      </t>

      <section title='"alg" (Algorithm Family) Parameter'>
	<t>
	  The <spanx style="verb">alg</spanx> (algorithm family) member
	  identifies the cryptographic algorithm family used with the key.
	  A list of defined
	  <spanx style="verb">alg</spanx> values is presented in
	  Section 5.1 of the
	  JSON Web Algorithms (JWA) <xref target="JWA" /> specification.
	  Specific additional members are
	  required to represent the key, depending upon the algorithm
	  family.  These members are specified in Section 5 of the
	  JSON Web Algorithms (JWA) <xref target="JWA" /> specification.
	  The <spanx style="verb">alg</spanx> value is case sensitive.
	  Its value MUST be a string.
	</t>
	<t>
	  <spanx style="verb">alg</spanx> values SHOULD either be
	  defined in the IANA JSON Web Key Algorithm Families registry
	  <xref target="JWA" /> or be
	  a URI that contains a collision resistant namespace.
	</t>
      </section>

      <section title='"use" (Key Use) Parameter'>
	<t>
	  The <spanx style="verb">use</spanx> (key use) member identifies the
	  intended use of the key.  Values defined by this
	  specification are <spanx style="verb">sig</spanx> (signature)
	  and <spanx style="verb">enc</spanx> (encryption).  Other values
	  MAY be used.
	  The <spanx style="verb">use</spanx> value is case sensitive.
	  Its value MUST be a string.
	  This member is OPTIONAL.
	</t>
      </section>

      <section title='"kid" (Key ID) Parameter'>
	<t>
	  The <spanx style="verb">kid</spanx> (key ID) member can
	  be used to match a specific key.  This can be used, for
	  instance, to choose among a set of keys within the JWK
	  during key rollover.
	  When used with JWS or JWE, the <spanx style="verb">kid</spanx>
	  value MAY be used to match a JWS or JWE <spanx style="verb">kid</spanx>
	  header parameter value.
	  The interpretation of the <spanx style="verb">kid</spanx> value is unspecified.
	  Its value MUST be a string.
	  This member is OPTIONAL.
	</t>
      </section>

    </section>

    <section title="JSON Web Key Set (JWK Set) Format" anchor="JWKSet">

      <t>
	A JSON Web Key Set (JWK Set) is a JSON object that contains
	an array of JSON Web Key values as the value of its
	<spanx style="verb">keys</spanx> member.
      </t>
      <t>
	The member names within a JWK Set MUST be unique;
	objects with duplicate member names MUST be rejected.
      </t>
      <t>
	Additional members MAY be present in the JWK Set.
	If present, they MUST be understood by implementations using them.
	Parameters for representing additional properties of JWK Sets
	SHOULD either be defined in the IANA JSON Web Key Set Parameters registry
	<xref target="JWKSetParamReg" /> or be
	a URI that contains a collision resistant namespace.
      </t>

      <section title='"keys" (JSON Web Key Set) Parameter'>
	<t>
	  The value of the <spanx style="verb">keys</spanx> (JSON Web Key Set)
	  member is an array of JSON Web Key (JWK) values.
	  This member is REQUIRED.
	</t>
      </section>
    </section>

    <section title="IANA Considerations" anchor="IANA">

      <section title="JSON Web Key Set Parameters Registry" anchor="JWKSetParamReg">
	<t>
	  This specification establishes the
	  IANA JSON Web Key Set Parameters registry
	  for reserved JWK Set parameter names.
	  Inclusion in the registry is RFC Required in the
	  <xref target="RFC5226">RFC 5226</xref> sense.
	  The registry records the reserved parameter name
	  and a reference to the RFC that defines it.
	  This specification registers the parameter names defined in
	  <xref target="JWKSet" />.
	</t>
      </section>

    </section>

    <section title="Security Considerations" anchor="Security">
      <t>
	A key is no more trustworthy than the method by which it was received.
      </t>
      <t>
	The security considerations in
	<xref target="W3C.CR-xmldsig-core2-20120124">XML DSIG 2.0</xref>,
	about public key representations also apply to this specification,
	other than those that are XML specific.
      </t>
    </section>

    <section title="Open Issues and Things To Be Done (TBD)" anchor="TBD">

      <t>
	The following items remain to be done in this draft:

	<list style="symbols">

	  <t>
	    (None at present)
	  </t>

	</list>
      </t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
      <?rfc include='http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml' ?>
      <?rfc include='http://xml.resource.org/public/rfc/bibxml/reference.RFC.4627.xml' ?>
      <?rfc include='http://xml.resource.org/public/rfc/bibxml/reference.RFC.4648.xml' ?>
      <?rfc include='http://xml.resource.org/public/rfc/bibxml/reference.RFC.5226.xml' ?>

      <reference anchor="JWA">
        <front>
	  <title>JSON Web Algorithms (JWA)</title>

	  <author fullname="Michael B. Jones" initials="M.B." surname="Jones">
	    <organization>Microsoft</organization>
	    <address>
	      <email>mbj@microsoft.com</email>
	      <uri>http://self-issued.info/</uri>
	    </address>
	  </author>

	  <date day="12" month="May" year="2012" />
        </front>
        <format target="http://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms" type="HTML" />
      </reference>

    </references>

    <references title="Informative References">

      <?rfc include="http://xml.resource.org/public/rfc/bibxml4/reference.W3C.CR-xmldsig-core2-20120124.xml" ?>

      <reference anchor="MagicSignatures">
        <front>
          <title>Magic Signatures</title>

          <author fullname="John Panzer (editor)" initials="J." surname="Panzer (editor)"></author>

          <author fullname="Ben Laurie" initials="B." surname="Laurie"></author>

          <author fullname="Dirk Balfanz" initials="D." surname="Balfanz"></author>

          <date day="7" month="January" year="2011" />
        </front>
        <format target="http://salmon-protocol.googlecode.com/svn/trunk/draft-panzer-magicsig-01.html" type="HTML" />
      </reference>

      <reference anchor="JWS">
        <front>
          <title>JSON Web Signature (JWS)</title>

	  <author fullname="Michael B. Jones" initials="M.B." surname="Jones">
	    <organization>Microsoft</organization>
	    <address>
	      <email>mbj@microsoft.com</email>
	      <uri>http://self-issued.info/</uri>
	    </address>
	  </author>

	  <author fullname="John Bradley" initials="J." surname="Bradley">
	    <organization abbrev="Ping Identity">Ping Identity</organization>
	    <address>
	      <email>ve7jtb@ve7jtb.com</email>
	    </address>
	  </author>

	  <author fullname="Nat Sakimura" initials="N." surname="Sakimura">
	    <organization abbrev="NRI">Nomura Research Institute</organization>
	    <address>
	      <email>n-sakimura@nri.co.jp</email>
	    </address>
	  </author>

	  <date day="12" month="May" year="2012" />
        </front>
        <format target="http://tools.ietf.org/html/draft-ietf-jose-json-web-signature" type="HTML" />
      </reference>

      <reference anchor="JWE">
        <front>
          <title>JSON Web Encryption (JWE)</title>

	  <author fullname="Michael B. Jones" initials="M.B." surname="Jones">
	    <organization>Microsoft</organization>
	    <address>
	      <email>mbj@microsoft.com</email>
	      <uri>http://self-issued.info/</uri>
	    </address>
	  </author>

	  <author fullname="Eric Rescorla" initials="E." surname="Rescorla">
	    <organization abbrev="RTFM">RTFM, Inc.</organization>
	    <address>
	      <email>ekr@rtfm.com</email>
	    </address>
	  </author>

	  <author fullname="Joe Hildebrand" initials="J." surname="Hildebrand">
	    <organization abbrev="Cisco">Cisco Systems, Inc.</organization>
	    <address>
	      <email>jhildebr@cisco.com</email>
	    </address>
	  </author>

	  <date day="12" month="May" year="2012" />
        </front>
        <format target="http://tools.ietf.org/html/draft-ietf-jose-json-web-encryption" type="HTML" />
      </reference>

    </references>

    <section title="Acknowledgements" anchor="Acknowledgements">

      <t>
	A JSON representation for RSA public keys was previously
	introduced in <xref target="MagicSignatures">Magic
	Signatures</xref>.
      </t>

    </section>

    <section title='Document History'>
      <t>
        -02
        <list style='symbols'>
	  <t>
	    Simplified JWK terminology to get replace the "JWK Key Object" and
	    "JWK Container Object" terms with simply "JSON Web Key (JWK)"
	    and "JSON Web Key Set (JWK Set)" and to eliminate potential
	    confusion between single keys and sets of keys.
	    As part of this change, the top-level member name for a
	    set of keys was changed from <spanx style="verb">jwk</spanx>
	    to <spanx style="verb">keys</spanx>.
	  </t>
	  <t>
	    Clarified that values with duplicate member names MUST be rejected.
	  </t>
	  <t>
	    Established JSON Web Key Set Parameters registry.
	  </t>
	  <t>
	    Explicitly listed non-goals in the introduction.
	  </t>
	  <t>
	    Moved algorithm-specific definitions from JWK to JWA.
	  </t>
          <t>
            Reformatted to give each member definition its own section heading.
          </t>
        </list>
      </t>
      <t>
        -01
        <list style='symbols'>
          <t>
	    Corrected the Magic Signatures reference.
          </t>
        </list>
      </t>
      <t>
        -00
        <list style='symbols'>
          <t>
            Created the initial IETF draft based upon
            draft-jones-json-web-key-03 with no normative changes.
          </t>
        </list>
      </t>
    </section>     

  </back>
</rfc>

PAFTECH AB 2003-20262026-04-23 03:06:24