W3C home > Mailing lists > Public > public-webcrypto@w3.org > July 2014

Re: Spec for CryptoKey.algorithm and CryptoKey.usages doesn't really make sense

From: Ryan Sleevi <sleevi@google.com>
Date: Mon, 14 Jul 2014 16:11:09 -0700
Message-ID: <CACvaWvauNk8pGA3+=vQk9L12LhsJJZ629wieiqKLLVESh69Zjg@mail.gmail.com>
To: Boris Zbarsky <bzbarsky@mit.edu>
Cc: "public-webcrypto@w3.org" <public-webcrypto@w3.org>, Domenic Denicola <domenic@domenicdenicola.com>
On Mon, Jul 14, 2014 at 3:45 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:

>  "Whatever makes everyone happy" ;)
> I want a unicorn too!  ;)
> Seriously, I think we'll get somewhere here.  I really do.
> Just to make sure we're on the same page, by the way, do the dictionaries
> coming from CryptoKey.algorithm ever have missing properties, or are they
> always completely filled in?
They're always completely filled in by the time normalization &
construction of the CryptoKey has happened, and they're immutable then and
forever more. Which is nice.

> Well, IDL could define it generically.  But you could define how to clone
> your particular dictionaries specifically.

Which is more or less what I'm already doing for the "copy an
ArrayBufferView" bit.

So we're on the same page, I'm imagining that it would (effectively) be
something like http://heycam.github.io/webidl/#es-dictionary 's step for
converting an IDL dictionary type to an ECMAScript Object, except that
instead of DefineOwnProperty, it's something like "construct an IDL value
whose type is the type member is declared to be of and that represents the
same value as member on source."

This covers the primitives (DOMString, bool, numerics), but presumably gets
grotty around object-sub-objects, which may involve some more magic
Received on Monday, 14 July 2014 23:11:36 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:02:51 UTC