Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upImplement Crypto.subtle #26878
Implement Crypto.subtle #26878
Comments
|
Hubs relies on the deriveKey, generateKey, importKey, exportKey, encrypt, and decrypt methods. |
|
Hubs relies specifically on: |
|
I've started tinkering in https://github.com/jdm/servo/tree/subtle. |
|
ring may be a useful basis for this work. Gecko relies on NSS (eg. https://searchfox.org/mozilla-central/rev/82c04b9cad5b98bdf682bd477f2b1e3071b004ad/dom/crypto/WebCryptoTask.cpp#2727 for the ECDH implementation for deriveKey). https://docs.rs/ring/0.16.15/ring/agreement/index.html has APIs involving ECDH, the P256 curve. However, it doesn't seem to have AES-CBC support. The RustCrypto group has https://docs.rs/aes/0.4.0/aes/ which looks like it might suit. Given that, we may just want to rely on the elliptic_curve and p256 crates instead of ring. |
https://www.w3.org/TR/WebCryptoAPI/#dfn-SubtleCrypto
This is used in the hub.link flow for joining a hubs room on a VR device.