Re: [Bug 24963] Export Key with "jwk" operations should return a JWK, rather than an ArrayBuffer

11 марта 2014 г., в 23:00, Ryan Sleevi <sleevi@google.com> написал(а):

> > As an implementor, I'm fine with exporting into an ArrayBuffer, as well as with importing from buffers. This is consistent with other formats, and - especially when importing - nicely avoids any complications that could arise while ingesting arbitrary JavaScript objects with their getters, loops and such.
> >
> 
> Can you explain this?
> 
> The complications are either addressed by WebIDL - in which case, they don't apply - or they equally apply to our use of the Algorithm dictionary, which means we have to solve them independent of this change.
> 
I see - so the proposal is to define dictionaries for each JWK kind, and to rely on WebIDL's algorithm for converting between JS objects and WebIDL objects.

Looks like WebCrypto may be the only spec that will use dictionaries as dictionary members, so this will put some non-trivial burden on implementations. But at least it's defined somewhere.

- WBR, Alexey Proskuryakov

Received on Wednesday, 12 March 2014 06:34:12 UTC