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

Issue 1774583002: Add IsAcceptableCipher, use instead of GetDefaultCipher. (Closed)

Created:
4 years, 9 months ago by torbjorng (webrtc)
Modified:
4 years, 9 months ago
Reviewers:
tommi, davidben_webrtc
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

Add IsAcceptableCipher, use instead of GetDefaultCipher. The old code insists on exact cipher suite matches with hardwired expectations. It does this matching parameterized with key type (RSA vs ECDSA) and TLS version (DTLS vs TLS and version 1.0 vs 1.2). This CL changes things to check against a white-list of cipher suites, with the check parameterized with key type (again RSA vs ECDSA). Then separately checks TLS version since the old implicit check of TLS version by means of resulting cipher suite was too blunt. Using a white list for cipher suites isn't perfect, but it is safe and requires minimal maintenance. It allows compatibility with not just one exact version of underlying crypto lib, but any version with reasonable defaults. The CL also re-enables critical tests which had to be disabled recently to allow a boringssl roll. BUG=webrtc:5634 Committed: https://crrev.com/43166b8adf749c6672eca0cd4a39399cf27d4761 Cr-Commit-Position: refs/heads/master@{#11951}

Patch Set 1 #

Patch Set 2 : Loop using modern C++ #

Patch Set 3 : Add mask to please Windows' compilers, list another ciphersuite #

Patch Set 4 : List another cipher suite #

Total comments: 4

Patch Set 5 : Remove GetDefaultSslCipherForTest and its usages #

Patch Set 6 : Rebase #

Patch Set 7 : Re-enable tests disabled as part of https://codereview.webrtc.org/1773543002 #

Patch Set 8 : Remove kDefaultSsl* constants #

Total comments: 7

Patch Set 9 : Provide and use method for checking TLS protocol version #

Patch Set 10 : Format #

Total comments: 8

Patch Set 11 : Address feedback #

Unified diffs Side-by-side diffs Delta from patch set Stats (+158 lines, -174 lines) Patch
M webrtc/api/peerconnection_unittest.cc View 1 2 3 4 5 6 7 8 9 7 chunks +19 lines, -46 lines 0 comments Download
M webrtc/base/opensslstreamadapter.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -3 lines 0 comments Download
M webrtc/base/opensslstreamadapter.cc View 1 2 3 4 5 6 7 8 9 10 3 chunks +83 lines, -81 lines 0 comments Download
M webrtc/base/sslstreamadapter.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +6 lines, -5 lines 0 comments Download
M webrtc/base/sslstreamadapter.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +6 lines, -4 lines 0 comments Download
M webrtc/base/sslstreamadapter_unittest.cc View 1 2 3 4 5 6 7 8 6 chunks +30 lines, -22 lines 0 comments Download
M webrtc/p2p/base/dtlstransportchannel_unittest.cc View 1 2 3 4 5 6 7 8 9 5 chunks +10 lines, -13 lines 0 comments Download

Messages

Total messages: 49 (22 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/1774583002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/1
4 years, 9 months ago (2016-03-07 18:53:50 UTC) #2
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: ios32_sim_dbg on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/ios32_sim_dbg/builds/5744) ios64_sim_dbg on ...
4 years, 9 months ago (2016-03-07 18:56:04 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/1774583002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/20001
4 years, 9 months ago (2016-03-07 20:57:39 UTC) #6
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_compile_dbg on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/win_compile_dbg/builds/3636)
4 years, 9 months ago (2016-03-07 21:04:07 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/40001
4 years, 9 months ago (2016-03-07 22:10:11 UTC) #10
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_msan on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/linux_msan/builds/8371)
4 years, 9 months ago (2016-03-07 23:08:06 UTC) #12
torbjorng (webrtc)
Tommi, please take an quick look, and just on the opensslstreamadapter.cc changes for now. I ...
4 years, 9 months ago (2016-03-07 23:18:12 UTC) #15
tommi
https://codereview.webrtc.org/1774583002/diff/60001/webrtc/api/peerconnection_unittest.cc File webrtc/api/peerconnection_unittest.cc (right): https://codereview.webrtc.org/1774583002/diff/60001/webrtc/api/peerconnection_unittest.cc#newcode1451 webrtc/api/peerconnection_unittest.cc:1451: EXPECT_TRUE_WAIT(rtc::SSLStreamAdapter::IsAcceptableCipher( Just curious - Instead of using the "WAIT" ...
4 years, 9 months ago (2016-03-07 23:47:26 UTC) #16
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/120001
4 years, 9 months ago (2016-03-08 18:33:28 UTC) #18
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: ios64_sim_dbg on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/ios64_sim_dbg/builds/5781) ios_arm64_rel on ...
4 years, 9 months ago (2016-03-08 18:34:59 UTC) #20
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/140001
4 years, 9 months ago (2016-03-08 19:21:06 UTC) #22
torbjorng (webrtc)
davidben, please take a look at the code in opensslstreamadapter,cc. tommi, PTAL. https://codereview.webrtc.org/1774583002/diff/60001/webrtc/api/peerconnection_unittest.cc File webrtc/api/peerconnection_unittest.cc ...
4 years, 9 months ago (2016-03-08 20:17:05 UTC) #24
davidben_webrtc
https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc#newcode1135 webrtc/base/opensslstreamadapter.cc:1135: KeyType key_type) { What is the test actually trying ...
4 years, 9 months ago (2016-03-08 20:29:05 UTC) #25
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: android_arm64_rel on tryserver.webrtc (JOB_TIMED_OUT, no build URL) ...
4 years, 9 months ago (2016-03-08 21:21:45 UTC) #27
torbjorng (webrtc)
Thanks, davidben, for the feedback! https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc#newcode1135 webrtc/base/opensslstreamadapter.cc:1135: KeyType key_type) { On ...
4 years, 9 months ago (2016-03-09 13:10:31 UTC) #28
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/180001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/180001
4 years, 9 months ago (2016-03-09 17:31:02 UTC) #30
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_baremetal on tryserver.webrtc (JOB_FAILED, http://build.chromium.org/p/tryserver.webrtc/builders/win_baremetal/builds/9590)
4 years, 9 months ago (2016-03-09 17:55:27 UTC) #32
davidben_webrtc
lgtm https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc#newcode1135 webrtc/base/opensslstreamadapter.cc:1135: KeyType key_type) { On 2016/03/09 13:10:31, torbjorng (webrtc) ...
4 years, 9 months ago (2016-03-09 20:30:26 UTC) #33
torbjorng (webrtc)
https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc#newcode1135 webrtc/base/opensslstreamadapter.cc:1135: KeyType key_type) { > I think it depends on ...
4 years, 9 months ago (2016-03-10 21:29:03 UTC) #35
tommi
lgtm with the below addressed. https://codereview.webrtc.org/1774583002/diff/180001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/180001/webrtc/base/opensslstreamadapter.cc#newcode1155 webrtc/base/opensslstreamadapter.cc:1155: #undef CDEF ? https://codereview.webrtc.org/1774583002/diff/180001/webrtc/base/opensslstreamadapter.h ...
4 years, 9 months ago (2016-03-10 21:37:59 UTC) #36
davidben_webrtc
https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/140001/webrtc/base/opensslstreamadapter.cc#newcode1135 webrtc/base/opensslstreamadapter.cc:1135: KeyType key_type) { On 2016/03/10 21:29:03, torbjorng (webrtc) wrote: ...
4 years, 9 months ago (2016-03-10 21:40:05 UTC) #37
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/200001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/200001
4 years, 9 months ago (2016-03-10 22:07:51 UTC) #39
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: android_arm64_rel on tryserver.webrtc (JOB_TIMED_OUT, no build URL) ...
4 years, 9 months ago (2016-03-11 00:08:26 UTC) #41
torbjorng (webrtc)
https://codereview.webrtc.org/1774583002/diff/180001/webrtc/base/opensslstreamadapter.cc File webrtc/base/opensslstreamadapter.cc (right): https://codereview.webrtc.org/1774583002/diff/180001/webrtc/base/opensslstreamadapter.cc#newcode1155 webrtc/base/opensslstreamadapter.cc:1155: On 2016/03/10 21:37:59, tommi-webrtc wrote: > #undef CDEF ? ...
4 years, 9 months ago (2016-03-11 07:50:18 UTC) #42
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1774583002/200001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1774583002/200001
4 years, 9 months ago (2016-03-11 08:05:13 UTC) #45
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years, 9 months ago (2016-03-11 08:06:52 UTC) #47
commit-bot: I haz the power
4 years, 9 months ago (2016-03-11 08:07:04 UTC) #49
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/43166b8adf749c6672eca0cd4a39399cf27d4761
Cr-Commit-Position: refs/heads/master@{#11951}

Powered by Google App Engine
This is Rietveld 408576698