<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>24963</bug_id>
          
          <creation_ts>2014-03-07 00:20:15 +0000</creation_ts>
          <short_desc>Export Key with &quot;jwk&quot; operations should return a Javascript object, rather than a JSON Web Key</short_desc>
          <delta_ts>2014-06-16 23:17:11 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Web Cryptography</product>
          <component>Web Cryptography API Document</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Windows NT</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ryan Sleevi">sleevi</reporter>
          <assigned_to name="Ryan Sleevi">sleevi</assigned_to>
          <cc>vijaybh</cc>
    
    <cc>watsonm</cc>
          
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>102041</commentid>
    <comment_count>0</comment_count>
    <who name="Ryan Sleevi">sleevi</who>
    <bug_when>2014-03-07 00:20:15 +0000</bug_when>
    <thetext>The export operations that take &quot;jwk&quot; as a format should return a Javascript Object that is a valid JWK, rather than returning an ArrayBuffer and requiring callers JSON.parse() it.

This may require specifying IDL definitions for JWK keys (presently: RSA and EC keys) that would conform to the JWK definition.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102042</commentid>
    <comment_count>1</comment_count>
    <who name="Ryan Sleevi">sleevi</who>
    <bug_when>2014-03-07 00:22:16 +0000</bug_when>
    <thetext>Bug filed based on this thread - http://lists.w3.org/Archives/Public/public-webcrypto/2014Mar/0059.html

Specifically, http://lists.w3.org/Archives/Public/public-webcrypto/2014Mar/0063.html and http://lists.w3.org/Archives/Public/public-webcrypto/2014Mar/0064.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102099</commentid>
    <comment_count>2</comment_count>
    <who name="Mark Watson">watsonm</who>
    <bug_when>2014-03-08 00:59:35 +0000</bug_when>
    <thetext>As per my comment on the mailing list, I disagree.

Serialized output aligns with the other formats and is necessary in any case for wrap/unwrap. We discussed and rejected providing object input / output instead some time ago and the reasons discussed then still apply now.

We should consider in Last Call whether to *add* the capability to import / export in object format. This would be an additional key format (e.g. &quot;jwk-js&quot;).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>104089</commentid>
    <comment_count>3</comment_count>
    <who name="Mark Watson">watsonm</who>
    <bug_when>2014-04-19 04:36:57 +0000</bug_when>
    <thetext>Based on the mailing list discussion, the simplicity of translation using the Encoding specification and the likely support for the Encoding specification, I&apos;ve changed my opinion on this and am ok with import / export accepting / returning Javascript objects as proposed.

Browsers still need to support (de)serialization of JWKs for the wrap/unwrap cases.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105062</commentid>
    <comment_count>4</comment_count>
    <who name="">vijaybh</who>
    <bug_when>2014-05-05 18:33:55 +0000</bug_when>
    <thetext>When this is fixed, this wording in 14.2 will also need to be updated to clarify that the return value is an object and not a serialization:

“jwk” “The key is represented as JSON according to the JSON Web Key format.” 

(see discussion in http://lists.w3.org/Archives/Public/public-webcrypto/2014Apr/0085.html)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>107900</commentid>
    <comment_count>5</comment_count>
    <who name="Ryan Sleevi">sleevi</who>
    <bug_when>2014-06-16 23:17:11 +0000</bug_when>
    <thetext>https://dvcs.w3.org/hg/webcrypto-api/rev/f61017a76a5d</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>