Chromium Code Reviews
DescriptionMaking RTCCertificate cloneable.
This CL makes RTCCertificate JavaScript objects cloneable according to the
structured clone algorithm as ordered by the WebRTC spec[1]. This makes it
possible to store and retrieve certificates persistently with IndexedDB.
Changes - RTCCertificate:
- WebRTCCertificate and implementation gets a toPEM() function.
- WebRTCCertificateGenerator and implementation gets a fromPEM() function.
- WebRTCCertificate no longer has keyParams(), this function was not used and
rtc::RTCCertificate currently has no function to retrieve the key params so
this information would be lost in the toPEM/fromPEM steps.
- ScriptValueSerializerForModules is updated to be able to write and read
RTCCertificate (using the PEM functions).
Changes - IndexedDB:
- indexeddb.js added with functions to manage a IndexedDB database for WebRTC
browser tests.
- WebRtcTestBase updated to call indexeddb.js functions from C++ test code.
- WebRtcBrowserTest: New test that saves and loads certificates.
Overview of certificate-related classes this CL touches (to aid reviewers):
- JavaScript RTCCertificate, internally contains a C++ version of certificate:
blink::RTCCertificate
- C++ versions of RTCCertificate (blink, content and webrtc layers):
blink::WebRTCCertificate < content::RTCCertificate > rtc::RTCCertificate
- Certificate generator & fromPEM factory (blink and content layers):
blink::WebRTCCertificateGenerator < content::RTCCertificateGenerator
(The abstractions (blink interface/content impl) are necessary to avoid illegal
dependencies.)
Depends on CLs (now landed):
- third_party/webrtc CL https://codereview.webrtc.org/1898383003/
which adds ToPEM/FromPEM to rtc::RTCCertificate.
- chromium CL https://codereview.chromium.org/1917133002/
which adds choosing certificates in WebRtcTestBase for WebRtcBrowserTest.
[1] https://w3c.github.io/webrtc-pc/archives/20160125/webrtc.html#attributes-6
BUG=chromium:581354
Patch Set 1 : #Patch Set 2 : Applied 1917133002 ps1 (WebRtcBrowserTest /w certificates) #Patch Set 3 : IndexedDB cloning of string (stand-in for RTCCertificate) #Patch Set 4 : Rebase /w master after dep CLs landed. ToPem -> ToPEM. #Patch Set 5 : Derp! #Messages
Total messages: 9 (8 generated)
|