Bug 122679 - [Meta] Implement WebCrypto SubtleCrypto interface
Summary: [Meta] Implement WebCrypto SubtleCrypto interface
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: HTML DOM (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on: 120954 122683 122770 122778 122972 123216 123461 123462 123466 123474 123476 123582 123587 123598 123628 123647 123659 123661 123669 123746 123767 124050 124059 124064 124161 124218 124236 124261 124280 124297 124335 124372 124376 124388 124442 124451 124466 124472 124473 124475 124483 124673 124725 124738 125084 125105 125114 125590 125641 125643 125647 125675 125696 127609 128027 128749 129121
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-11 14:40 PDT by Alexey Proskuryakov
Modified: 2016-08-15 18:40 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Proskuryakov 2013-10-11 14:40:46 PDT
This is a meta for adding SubtleCrypto from <http://dvcs.w3.org/hg/webcrypto-api/raw-file/tip/spec/Overview.html>.
Comment 1 Alexey Proskuryakov 2013-11-03 01:04:17 PST
<rdar://problem/15172764>
Comment 2 Alexey Proskuryakov 2013-12-04 11:02:49 PST
WebKit currently implements latest WebCrypto editor's draft posted 2013-08-30 (<https://dvcs.w3.org/hg/webcrypto-api/raw-file/dffe14c6052a/spec/Overview.html>), with a few updates:

- operations take CryptoOperationData arguments, not sequences of those;
- added AES-KW algorithm (RFC3394).

SubtleCrypto is exposed as window.crypto.webkitSubtle. The spec hasn't even reached Last Call yet, so it's likely to change in the future.

Supported algorithms are:
- SHA-1, SHA-224, SHA-256, SHA-384, SHA-512 (all of these are also supported as hashes for below algorithms);
- HMAC;
- AES-CBC;
- AES-KW;
- RSA-OAEP;
- RSASSA-PKCS1-v1_5.

All operations relevant to these algorithms are supported. Key algorithm, usages and extractable members are enforced.

Key import, export, unwrapping and wrapping are supported for raw and JWK formats (JWK mapping is implemented according to <https://www.w3.org/Bugs/Public/show_bug.cgi?id=23796#c12>). Imported private RSA keys currently must have additional prime factor data, and must have exactly two prime factors.

Most of the code is cross platforms, with low level cryptography operations invoking Mac platform libraries.

The functionality is present in WebKit nightly builds on OS X 10.9 Mavericks (http://nightly.webkit.org). Please test, and report any bugs! Patches for additional algorithms and key formats are welcome.
Comment 3 Jiewen Tan 2016-08-15 18:39:41 PDT
Close this bug as fixed as all the depending unfixed bugs have been moved to either Bug 160880 and Bug 160883.