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

Issue 1883813002: RTCCertificateGenerator added. (Closed)

Created:
4 years, 8 months ago by hbos
Modified:
4 years, 8 months ago
CC:
webrtc-reviews_webrtc.org, tterriberry_mozilla.com
Base URL:
https://chromium.googlesource.com/external/webrtc.git@master
Target Ref:
refs/pending/heads/master
Project:
webrtc
Visibility:
Public.

Description

RTCCertificateGenerator added. This is a new way of generating RTCCertificate objects that is meant to replace DtlsIdentityStoreInterface and all of its implementations (clean up work). It is similar to the identity store in that it generates on the worker thread and does callback on the signaling thread, but: - It does not generate identities in the background that you did not ask for (preemptive generation made more sense before certificates were parameterized, not so much anymore, and ECDSA which will be most common takes like <=2 ms to generate). - As such this code is less complicated than the store's code. - The API is different, it takes Optional<uint64_t> expires and it returns RTCCertificates, not SSLIdentities. - It supports a blocking version of GenerateCertificate that can be called from any thread, necessary for Chrome which can generate certificates before the signaling/worker threads have been initialized as WebRTC-threads (Chrome can invoke this version on the worker thread outside of WebRTC). This CL does not remove the identity store, only adds the alternative. Follow-up CLs will start using it, the store will be removed once it is no longer used anywhere. BUG=webrtc:5707, webrtc:5708 R=hta@webrtc.org, torbjorng@webrtc.org Committed: https://crrev.com/da3a1da9b192e05153219745eb156d1ad469a495 Cr-Commit-Position: refs/heads/master@{#12381}

Patch Set 1 #

Patch Set 2 : Updated comments and made it compile (using override everywhere, etc) #

Total comments: 20

Patch Set 3 : Addressed hta's comments #

Total comments: 6

Patch Set 4 : Addressed comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+382 lines, -0 lines) Patch
M webrtc/base/BUILD.gn View 1 chunk +2 lines, -0 lines 0 comments Download
M webrtc/base/base.gyp View 1 chunk +2 lines, -0 lines 0 comments Download
M webrtc/base/base_tests.gyp View 1 chunk +1 line, -0 lines 0 comments Download
A webrtc/base/rtccertificategenerator.h View 1 2 3 1 chunk +69 lines, -0 lines 0 comments Download
A webrtc/base/rtccertificategenerator.cc View 1 2 3 1 chunk +157 lines, -0 lines 0 comments Download
A webrtc/base/rtccertificategenerator_unittest.cc View 1 2 3 1 chunk +151 lines, -0 lines 0 comments Download

Messages

Total messages: 34 (17 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1883813002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1883813002/1
4 years, 8 months ago (2016-04-13 12:27:22 UTC) #2
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: ios_dbg on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/ios_dbg/builds/14161) mac_baremetal on ...
4 years, 8 months ago (2016-04-13 12:28:54 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1883813002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1883813002/40001
4 years, 8 months ago (2016-04-13 13:06:46 UTC) #7
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1883813002/30007 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1883813002/30007
4 years, 8 months ago (2016-04-13 13:19:46 UTC) #11
hbos
Please take a look hta, torbjorng. The RTCCertificateGenerator is akin to RTCPeerConnection.generateCertificate in the WebRTC ...
4 years, 8 months ago (2016-04-13 13:34:29 UTC) #15
hbos
https://codereview.webrtc.org/1883813002/diff/30007/webrtc/base/rtccertificategenerator_unittest.cc File webrtc/base/rtccertificategenerator_unittest.cc (right): https://codereview.webrtc.org/1883813002/diff/30007/webrtc/base/rtccertificategenerator_unittest.cc#newcode114 webrtc/base/rtccertificategenerator_unittest.cc:114: // but does not verify that this clock is ...
4 years, 8 months ago (2016-04-13 13:40:34 UTC) #16
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 8 months ago (2016-04-13 14:21:05 UTC) #18
hta-webrtc
Mainly looks good, but a number of language-ish comments. About Blockingly (my peeviest peevee): I ...
4 years, 8 months ago (2016-04-14 11:54:05 UTC) #19
hbos
PTAL hta, torbjorng. Ah, I guess I made sentences more compact at the expense of ...
4 years, 8 months ago (2016-04-14 15:31:55 UTC) #21
hbos
https://codereview.webrtc.org/1883813002/diff/30007/webrtc/base/rtccertificategenerator.cc File webrtc/base/rtccertificategenerator.cc (right): https://codereview.webrtc.org/1883813002/diff/30007/webrtc/base/rtccertificategenerator.cc#newcode108 webrtc/base/rtccertificategenerator.cc:108: uint64_t expires_s = *expires_ms / 1000; On 2016/04/14 15:31:54, ...
4 years, 8 months ago (2016-04-15 07:59:21 UTC) #22
hta-webrtc
lgtm https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator_unittest.cc File webrtc/base/rtccertificategenerator_unittest.cc (right): https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator_unittest.cc#newcode132 webrtc/base/rtccertificategenerator_unittest.cc:132: EXPECT_GE(expires_diff, kExpiresMs - 2*kGenerationTimeoutMs - 1000); Since cert ...
4 years, 8 months ago (2016-04-15 10:42:23 UTC) #23
torbjorng (webrtc)
lgtm https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator.cc File webrtc/base/rtccertificategenerator.cc (right): https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator.cc#newcode114 webrtc/base/rtccertificategenerator.cc:114: if (expires_s > kYearInSeconds) Consider using std::max. https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator.h ...
4 years, 8 months ago (2016-04-15 12:17:48 UTC) #24
hbos
https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator.cc File webrtc/base/rtccertificategenerator.cc (right): https://codereview.webrtc.org/1883813002/diff/90001/webrtc/base/rtccertificategenerator.cc#newcode114 webrtc/base/rtccertificategenerator.cc:114: if (expires_s > kYearInSeconds) On 2016/04/15 12:17:48, torbjorng (webrtc) ...
4 years, 8 months ago (2016-04-15 13:24:14 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1883813002/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1883813002/110001
4 years, 8 months ago (2016-04-15 13:24:33 UTC) #28
commit-bot: I haz the power
Try jobs failed on following builders: android_arm64_rel on tryserver.webrtc (JOB_TIMED_OUT, no build URL) linux_baremetal on ...
4 years, 8 months ago (2016-04-15 15:25:10 UTC) #30
hbos
Committed patchset #4 (id:110001) manually as da3a1da9b192e05153219745eb156d1ad469a495 (presubmit successful).
4 years, 8 months ago (2016-04-15 15:55:36 UTC) #33
commit-bot: I haz the power
4 years, 8 months ago (2016-04-15 15:55:37 UTC) #34
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/da3a1da9b192e05153219745eb156d1ad469a495
Cr-Commit-Position: refs/heads/master@{#12381}

Powered by Google App Engine
This is Rietveld 408576698