Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Issue 179353002: [webcrypto] Add the KeyAlgorithm interface. (Closed)

Created:
6 years, 10 months ago by eroman
Modified:
6 years, 10 months ago
CC:
blink-reviews, Nils Barth (inactive), jamesr, kojih, arv+blink, jsbell+bindings_chromium.org, Mads Ager (chromium), sof, abarth-chromium, marja+watch_chromium.org, dglazkov+blink, adamk+blink_chromium.org, haraken, Nate Chapin, Inactive
Visibility:
Public.

Description

[webcrypto] Add the KeyAlgorithm interface. This matches the changes in https://dvcs.w3.org/hg/webcrypto-api/rev/2fa3494f0179 * Key.algorithm is now reflected as a KeyAlgorithm interface rather than Algorithm * HMAC no longer takes the hash as an operational parameter (key move to import/generation) * RSA-SSA no longer takes the hash as an operation (move to key import/generation)parameter BUG=245025 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=167979

Patch Set 1 : #

Total comments: 6

Patch Set 2 : Inline the empty trace() #

Total comments: 22

Patch Set 3 : remove test for public key extractability #

Patch Set 4 : Address haraken's comments #

Total comments: 2

Patch Set 5 : Rebase (consequence is the removal of DEFINE_GC_INFO from KeyAlgorithm.h/cc) #

Patch Set 6 : rebase onto master #

Patch Set 7 : rebase onto master #

Patch Set 8 : appease unreachable warning #

Patch Set 9 : rebase yet again (another conflict) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+922 lines, -530 lines) Patch
M LayoutTests/crypto/encrypt-decrypt.html View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/crypto/encrypt-decrypt-expected.txt View 1 2 3 4 5 6 1 chunk +4 lines, -0 lines 0 comments Download
M LayoutTests/crypto/exportKey.html View 1 chunk +7 lines, -1 line 0 comments Download
M LayoutTests/crypto/exportKey-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/crypto/generateKey-expected.txt View 1 chunk +14 lines, -14 lines 0 comments Download
M LayoutTests/crypto/importKey.html View 1 2 4 chunks +52 lines, -13 lines 0 comments Download
M LayoutTests/crypto/importKey-expected.txt View 1 2 2 chunks +17 lines, -1 line 0 comments Download
M LayoutTests/crypto/resources/common.js View 1 2 3 4 5 6 1 chunk +17 lines, -7 lines 0 comments Download
M LayoutTests/crypto/sign-verify.html View 5 chunks +8 lines, -19 lines 0 comments Download
M LayoutTests/crypto/sign-verify-expected.txt View 3 chunks +9 lines, -17 lines 0 comments Download
M Source/heap/ThreadState.h View 1 2 3 4 5 6 7 8 2 chunks +1 line, -1 line 0 comments Download
A + Source/modules/crypto/AesKeyAlgorithm.h View 1 2 3 4 5 2 chunks +13 lines, -11 lines 0 comments Download
A + Source/modules/crypto/AesKeyAlgorithm.cpp View 1 2 3 4 2 chunks +15 lines, -9 lines 0 comments Download
A + Source/modules/crypto/AesKeyAlgorithm.idl View 1 2 3 1 chunk +4 lines, -1 line 0 comments Download
D Source/modules/crypto/Algorithm.h View 1 2 3 4 1 chunk +0 lines, -61 lines 0 comments Download
D Source/modules/crypto/Algorithm.cpp View 1 2 3 4 1 chunk +0 lines, -55 lines 0 comments Download
D Source/modules/crypto/Algorithm.idl View 1 chunk +0 lines, -36 lines 0 comments Download
A + Source/modules/crypto/HmacKeyAlgorithm.h View 1 2 3 1 chunk +16 lines, -8 lines 0 comments Download
A + Source/modules/crypto/HmacKeyAlgorithm.cpp View 1 2 3 4 2 chunks +17 lines, -9 lines 0 comments Download
A + Source/modules/crypto/HmacKeyAlgorithm.idl View 1 2 3 1 chunk +4 lines, -1 line 0 comments Download
M Source/modules/crypto/Key.h View 1 2 3 4 3 chunks +4 lines, -4 lines 0 comments Download
M Source/modules/crypto/Key.cpp View 1 2 3 4 4 chunks +3 lines, -30 lines 0 comments Download
M Source/modules/crypto/Key.idl View 1 chunk +1 line, -1 line 0 comments Download
A + Source/modules/crypto/KeyAlgorithm.h View 1 2 3 4 1 chunk +19 lines, -9 lines 0 comments Download
A Source/modules/crypto/KeyAlgorithm.cpp View 1 2 3 4 5 6 7 1 chunk +107 lines, -0 lines 0 comments Download
A + Source/modules/crypto/KeyAlgorithm.idl View 1 2 3 1 chunk +3 lines, -4 lines 0 comments Download
M Source/modules/crypto/KeyPair.h View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M Source/modules/crypto/NormalizeAlgorithm.cpp View 1 2 3 4 5 6 6 chunks +62 lines, -26 lines 0 comments Download
A + Source/modules/crypto/RsaHashedKeyAlgorithm.h View 1 2 3 4 5 1 chunk +12 lines, -16 lines 0 comments Download
A + Source/modules/crypto/RsaHashedKeyAlgorithm.cpp View 1 2 3 4 2 chunks +17 lines, -9 lines 0 comments Download
A + Source/modules/crypto/RsaHashedKeyAlgorithm.idl View 1 2 3 2 chunks +3 lines, -4 lines 0 comments Download
A + Source/modules/crypto/RsaKeyAlgorithm.h View 1 2 3 4 5 1 chunk +14 lines, -14 lines 0 comments Download
A + Source/modules/crypto/RsaKeyAlgorithm.cpp View 1 2 3 4 2 chunks +30 lines, -9 lines 0 comments Download
A + Source/modules/crypto/RsaKeyAlgorithm.idl View 1 2 3 1 chunk +4 lines, -4 lines 0 comments Download
M Source/modules/modules.gypi View 1 2 3 4 3 chunks +15 lines, -3 lines 0 comments Download
M Source/platform/blink_platform.gypi View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M Source/platform/exported/WebCryptoAlgorithm.cpp View 2 chunks +22 lines, -14 lines 0 comments Download
M Source/platform/exported/WebCryptoKey.cpp View 4 chunks +6 lines, -4 lines 0 comments Download
A Source/platform/exported/WebCryptoKeyAlgorithm.cpp View 1 chunk +122 lines, -0 lines 0 comments Download
M public/platform/WebCrypto.h View 1 chunk +3 lines, -0 lines 0 comments Download
M public/platform/WebCryptoAlgorithm.h View 3 chunks +12 lines, -9 lines 0 comments Download
M public/platform/WebCryptoAlgorithmParams.h View 5 chunks +68 lines, -56 lines 0 comments Download
M public/platform/WebCryptoKey.h View 3 chunks +3 lines, -3 lines 0 comments Download
A + public/platform/WebCryptoKeyAlgorithm.h View 2 chunks +38 lines, -46 lines 0 comments Download
A public/platform/WebCryptoKeyAlgorithmParams.h View 1 chunk +151 lines, -0 lines 0 comments Download

Messages

Total messages: 23 (0 generated)
eroman
6 years, 10 months ago (2014-02-25 06:39:06 UTC) #1
haraken
Once the CL looks OK in terms of semantics, I'm happy to review in terms ...
6 years, 10 months ago (2014-02-25 06:41:51 UTC) #2
abarth-chromium
lgtm https://codereview.chromium.org/179353002/diff/20001/Source/modules/crypto/AesKeyAlgorithm.h File Source/modules/crypto/AesKeyAlgorithm.h (right): https://codereview.chromium.org/179353002/diff/20001/Source/modules/crypto/AesKeyAlgorithm.h#newcode49 Source/modules/crypto/AesKeyAlgorithm.h:49: void trace(Visitor*); I don't think this is needed ...
6 years, 10 months ago (2014-02-25 07:51:41 UTC) #3
eroman
Thanks! @haraken: Could you take a look at the oilpan side of things, and give ...
6 years, 10 months ago (2014-02-25 08:33:14 UTC) #4
Mads Ager (chromium)
LGTM on the oilpan side. You can test it by putting enable_oilpan=1 in your GYP_DEFINES ...
6 years, 10 months ago (2014-02-25 08:49:24 UTC) #5
haraken
https://codereview.chromium.org/179353002/diff/40001/Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp File Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp (right): https://codereview.chromium.org/179353002/diff/40001/Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp#newcode42 Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp:42: v8::Handle<v8::Object> wrap(KeyAlgorithm* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate) Probably you ...
6 years, 10 months ago (2014-02-25 09:15:45 UTC) #6
Mads Ager (chromium)
https://codereview.chromium.org/179353002/diff/40001/Source/modules/crypto/RsaHashedKeyAlgorithm.h File Source/modules/crypto/RsaHashedKeyAlgorithm.h (right): https://codereview.chromium.org/179353002/diff/40001/Source/modules/crypto/RsaHashedKeyAlgorithm.h#newcode44 Source/modules/crypto/RsaHashedKeyAlgorithm.h:44: void trace(Visitor*); On 2014/02/25 09:15:46, haraken wrote: > > ...
6 years, 10 months ago (2014-02-25 09:34:17 UTC) #7
eroman
Thanks for the comments haraken/mads! https://codereview.chromium.org/179353002/diff/40001/Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp File Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp (right): https://codereview.chromium.org/179353002/diff/40001/Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp#newcode42 Source/bindings/v8/custom/V8KeyAlgorithmCustom.cpp:42: v8::Handle<v8::Object> wrap(KeyAlgorithm* impl, v8::Handle<v8::Object> ...
6 years, 10 months ago (2014-02-26 01:37:35 UTC) #8
haraken
Thanks for the update! LGTM. https://codereview.chromium.org/179353002/diff/80001/public/platform/WebCrypto.h File public/platform/WebCrypto.h (right): https://codereview.chromium.org/179353002/diff/80001/public/platform/WebCrypto.h#newcode40 public/platform/WebCrypto.h:40: #define WEBCRYPTO_HAS_KEY_ALGORITHM 1 Where ...
6 years, 10 months ago (2014-02-26 02:33:09 UTC) #9
eroman
https://codereview.chromium.org/179353002/diff/80001/public/platform/WebCrypto.h File public/platform/WebCrypto.h (right): https://codereview.chromium.org/179353002/diff/80001/public/platform/WebCrypto.h#newcode40 public/platform/WebCrypto.h:40: #define WEBCRYPTO_HAS_KEY_ALGORITHM 1 On 2014/02/26 02:33:09, haraken wrote: > ...
6 years, 10 months ago (2014-02-26 02:35:42 UTC) #10
eroman
The CQ bit was checked by eroman@chromium.org
6 years, 10 months ago (2014-02-26 15:47:13 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/eroman@chromium.org/179353002/120001
6 years, 10 months ago (2014-02-26 15:47:27 UTC) #12
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-26 15:47:37 UTC) #13
commit-bot: I haz the power
Failed to apply patch for Source/modules/crypto/RsaHashedKeyAlgorithm.h: While running patch -p1 --forward --force --no-backup-if-mismatch; A Source/modules/crypto/RsaHashedKeyAlgorithm.h ...
6 years, 10 months ago (2014-02-26 15:47:37 UTC) #14
eroman
The CQ bit was checked by eroman@chromium.org
6 years, 10 months ago (2014-02-26 19:57:39 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/eroman@chromium.org/179353002/160001
6 years, 10 months ago (2014-02-26 19:57:49 UTC) #16
eroman
The CQ bit was checked by eroman@chromium.org
6 years, 10 months ago (2014-02-26 21:02:18 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/eroman@chromium.org/179353002/180001
6 years, 10 months ago (2014-02-26 21:02:32 UTC) #18
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-27 00:06:53 UTC) #19
commit-bot: I haz the power
Retried try job too often on win_layout for step(s) webkit_lint http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win_layout&number=23593
6 years, 10 months ago (2014-02-27 00:06:54 UTC) #20
eroman
The CQ bit was checked by eroman@chromium.org
6 years, 10 months ago (2014-02-27 00:13:47 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/eroman@chromium.org/179353002/200001
6 years, 10 months ago (2014-02-27 00:14:31 UTC) #22
commit-bot: I haz the power
6 years, 10 months ago (2014-02-27 04:10:23 UTC) #23
Message was sent while issue was closed.
Change committed as 167979

Powered by Google App Engine
This is Rietveld 408576698