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

Issue 2291213002: Remove ENGINE indirection from Android SSLPrivateKey. (Closed)

Created:
4 years, 3 months ago by davidben
Modified:
4 years, 3 months ago
Reviewers:
Ted C, svaldez, boliu, Torne
CC:
chromium-reviews, cbentzel+watch_chromium.org, android-webview-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove ENGINE indirection from Android SSLPrivateKey. Instead, implement ThreadedSSLPrivateKey::Delegate directly using the JNI functions. This removes all of Chromium's uses of RSA_METHOD and ECDSA_METHOD. Rather than a function from jobject to EVP_PKEY exposed by keystore_openssl.h, have SSLPlatformKeyAndroid expose a function from jobject to SSLPrivateKey. That then gets routed through whereever the EVP_PKEY used to be routed. In particular, OpenSSLClientKeyStore now acts on a scoped_refptr<SSLPrivateKey> rather than a crypto::ScopedEVP_PKEY. OpenSSLClientKeyStore is also rewritten to be much simpler, but all its problems (like not being thread-safe) still remain. That will be resolved by finishing the SSLPrivateKey refactor and routing it up through //content so we can do away with the inherently global FetchClientCertPrivateKey. Port the old keystore_unittests.cc tests to test the new wrapper. Trim it down a little so it tests just the wrapper object, but test all hashes. BUG=394131 Committed: https://crrev.com/1504dd71c6743e950147eca8f0ef06388d311073 Cr-Commit-Position: refs/heads/master@{#416258}

Patch Set 1 #

Patch Set 2 : fixup #

Total comments: 1

Patch Set 3 : appease clang #

Patch Set 4 : Fix WebView build #

Total comments: 6

Patch Set 5 : address comments and remove some unnecessary .get()s #

Total comments: 3

Patch Set 6 : rebase #

Patch Set 7 : re-delete undeleted files #

Unified diffs Side-by-side diffs Delta from patch set Stats (+738 lines, -1428 lines) Patch
M android_webview/native/aw_contents_client_bridge.cc View 1 2 3 4 5 6 chunks +13 lines, -10 lines 0 comments Download
M chrome/browser/ui/android/ssl_client_certificate_request.cc View 1 2 3 4 4 chunks +11 lines, -10 lines 0 comments Download
D net/android/keystore_openssl.h View 1 2 3 4 5 6 1 chunk +0 lines, -50 lines 0 comments Download
D net/android/keystore_openssl.cc View 1 2 3 4 5 6 1 chunk +0 lines, -552 lines 0 comments Download
D net/android/keystore_unittest.cc View 1 2 3 4 5 6 1 chunk +0 lines, -541 lines 0 comments Download
M net/net.gypi View 1 2 3 4 5 3 chunks +1 line, -3 lines 0 comments Download
M net/ssl/openssl_client_key_store.h View 2 chunks +14 lines, -42 lines 0 comments Download
M net/ssl/openssl_client_key_store.cc View 1 2 3 4 1 chunk +45 lines, -84 lines 0 comments Download
M net/ssl/openssl_client_key_store_unittest.cc View 1 2 3 4 6 chunks +75 lines, -72 lines 0 comments Download
A + net/ssl/ssl_platform_key_android.h View 1 2 3 4 5 2 chunks +8 lines, -8 lines 0 comments Download
M net/ssl/ssl_platform_key_android.cc View 1 2 3 4 5 2 chunks +185 lines, -56 lines 0 comments Download
A net/ssl/ssl_platform_key_android_unittest.cc View 1 2 3 4 5 1 chunk +386 lines, -0 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 50 (36 generated)
davidben
https://codereview.chromium.org/2291213002/diff/20001/net/ssl/ssl_platform_key_android_unittest.cc File net/ssl/ssl_platform_key_android_unittest.cc (right): https://codereview.chromium.org/2291213002/diff/20001/net/ssl/ssl_platform_key_android_unittest.cc#newcode1 net/ssl/ssl_platform_key_android_unittest.cc:1: // Copyright (c) 2013 The Chromium Authors. All rights ...
4 years, 3 months ago (2016-08-30 20:08:32 UTC) #10
davidben
Fix WebView build
4 years, 3 months ago (2016-08-30 21:00:58 UTC) #17
svaldez
lgtm als->also in CL description and a few nits. https://codereview.chromium.org/2291213002/diff/60001/android_webview/native/aw_contents_client_bridge.cc File android_webview/native/aw_contents_client_bridge.cc (right): https://codereview.chromium.org/2291213002/diff/60001/android_webview/native/aw_contents_client_bridge.cc#newcode243 android_webview/native/aw_contents_client_bridge.cc:243: ...
4 years, 3 months ago (2016-09-01 14:51:05 UTC) #22
davidben
(Also removed some unnecessary .gets()) +tedchoc for chrome/browser/ui/android/ssl_client_certificate_request.cc +boliu for android_webview/native/aw_contents_client_bridge.cc https://codereview.chromium.org/2291213002/diff/60001/android_webview/native/aw_contents_client_bridge.cc File android_webview/native/aw_contents_client_bridge.cc (right): ...
4 years, 3 months ago (2016-09-01 19:40:56 UTC) #27
Ted C
On 2016/09/01 19:40:56, davidben wrote: > (Also removed some unnecessary .gets()) > > +tedchoc for ...
4 years, 3 months ago (2016-09-01 20:13:02 UTC) #30
boliu
https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc File android_webview/native/aw_contents_client_bridge.cc (right): https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc#newcode261 android_webview/native/aw_contents_client_bridge.cc:261: base::Bind(&RecordClientCertificateKey, base::RetainedRef(client_cert), is RetainedRef necessary here? (/me seeing it ...
4 years, 3 months ago (2016-09-01 20:22:30 UTC) #31
davidben
https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc File android_webview/native/aw_contents_client_bridge.cc (right): https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc#newcode261 android_webview/native/aw_contents_client_bridge.cc:261: base::Bind(&RecordClientCertificateKey, base::RetainedRef(client_cert), On 2016/09/01 20:22:30, boliu wrote: > is ...
4 years, 3 months ago (2016-09-01 20:28:01 UTC) #32
boliu
lgtm https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc File android_webview/native/aw_contents_client_bridge.cc (right): https://codereview.chromium.org/2291213002/diff/80001/android_webview/native/aw_contents_client_bridge.cc#newcode261 android_webview/native/aw_contents_client_bridge.cc:261: base::Bind(&RecordClientCertificateKey, base::RetainedRef(client_cert), On 2016/09/01 20:28:01, davidben wrote: > ...
4 years, 3 months ago (2016-09-01 20:35:53 UTC) #33
davidben
This ended up being a non-trivial rebase due to the JavaRef work. +torne, do you ...
4 years, 3 months ago (2016-09-01 20:56:57 UTC) #36
davidben
On 2016/09/01 20:56:57, davidben wrote: > This ended up being a non-trivial rebase due to ...
4 years, 3 months ago (2016-09-01 20:57:42 UTC) #38
Torne
On 2016/09/01 20:57:42, davidben wrote: > On 2016/09/01 20:56:57, davidben wrote: > > This ended ...
4 years, 3 months ago (2016-09-02 12:04:31 UTC) #43
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2291213002/120001
4 years, 3 months ago (2016-09-02 13:41:52 UTC) #46
commit-bot: I haz the power
Committed patchset #7 (id:120001)
4 years, 3 months ago (2016-09-02 13:45:35 UTC) #48
commit-bot: I haz the power
4 years, 3 months ago (2016-09-02 13:46:57 UTC) #50
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/1504dd71c6743e950147eca8f0ef06388d311073
Cr-Commit-Position: refs/heads/master@{#416258}

Powered by Google App Engine
This is Rietveld 408576698