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

Issue 165191: Implement SSL certificate error handling on the Mac. If the user gives... (Closed)

Created:
11 years, 4 months ago by wtc
Modified:
9 years, 7 months ago
CC:
chromium-reviews_googlegroups.com, John Grabowski, darin (slow to review), brettw, willchan no longer on Chromium
Visibility:
Public.

Description

Implement SSL certificate error handling on the Mac. If the user gives us bad certs to allow, we tell SecureTransport to not verify the server cert, and only allow the cert to be one of the bad certs the user allows. In the future we should figure out how to verify the server cert ourselves. R=avi,eroman BUG=http://crbug.com/11983 TEST=Visit https://www.ssl247.com/ and https://alioth.debian.org/. Clicking the "Proceed anyway" button should bring you to the site with a red "https" in the location bar. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=23321

Patch Set 1 #

Patch Set 2 : Add Windows and Linux files #

Patch Set 3 : Fix order of parameters for IsAllowedBadCert #

Patch Set 4 : Move IsAllowedBadCert to ssl_config_service.h #

Total comments: 18

Patch Set 5 : Address all review comments except adding new function for checking allowed_bad_certs #

Patch Set 6 : Rewrite CopyServerCert to return X509Certificate* instead of SecCertificateRef #

Total comments: 1

Patch Set 7 : Use DCHECK_GT #

Patch Set 8 : CopyServerCert => GetServerCert #

Patch Set 9 : Upload before checkin #

Unified diffs Side-by-side diffs Delta from patch set Stats (+100 lines, -50 lines) Patch
M net/base/ssl_config_service.h View 1 2 3 4 5 6 7 8 3 chunks +25 lines, -9 lines 0 comments Download
M net/http/http_network_transaction.cc View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -1 line 0 comments Download
M net/socket/ssl_client_socket_mac.h View 6 7 8 1 chunk +2 lines, -0 lines 0 comments Download
M net/socket/ssl_client_socket_mac.cc View 1 2 3 4 5 6 7 8 4 chunks +62 lines, -33 lines 0 comments Download
M net/socket/ssl_client_socket_nss.cc View 2 3 4 5 6 7 8 2 chunks +4 lines, -4 lines 0 comments Download
M net/socket/ssl_client_socket_win.cc View 2 3 4 5 6 7 8 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
wtc
11 years, 4 months ago (2009-08-10 21:46:22 UTC) #1
Avi (use Gerrit)
With function name change and scoped pointer change, LGTM. http://codereview.chromium.org/165191/diff/1008/1010 File net/socket/ssl_client_socket_mac.cc (right): http://codereview.chromium.org/165191/diff/1008/1010#newcode246 Line ...
11 years, 4 months ago (2009-08-11 14:35:58 UTC) #2
eroman
http://codereview.chromium.org/165191/diff/1008/1011 File net/base/ssl_config_service.h (right): http://codereview.chromium.org/165191/diff/1008/1011#newcode6 Line 6: #define NET_BASE_SSL_CONFIG_SERVICE_H__ If you are bored, could be ...
11 years, 4 months ago (2009-08-11 18:25:08 UTC) #3
eroman
Also, I am concerned that we are not adding any unit tests with HTTPS bug ...
11 years, 4 months ago (2009-08-11 18:27:16 UTC) #4
wtc
Please review the new Patch Set. avi: I changed GetServerCert to return X509Certificate* instead of ...
11 years, 4 months ago (2009-08-12 22:02:10 UTC) #5
Avi (use Gerrit)
On 2009/08/12 22:02:10, wtc wrote: > Do you think I should use "Copy" here even ...
11 years, 4 months ago (2009-08-12 22:06:53 UTC) #6
eroman
lgtm http://codereview.chromium.org/165191/diff/41/1027 File net/socket/ssl_client_socket_mac.cc (right): http://codereview.chromium.org/165191/diff/41/1027#newcode252 Line 252: DCHECK(CFArrayGetCount(certs) > 0); DCHECK_GT ?
11 years, 4 months ago (2009-08-13 02:55:23 UTC) #7
wtc
11 years, 4 months ago (2009-08-14 22:36:12 UTC) #8
On 2009/08/11 18:27:16, eroman wrote:
> Also, I am concerned that we are not adding any unit tests with HTTPS bug
fixes.

As promised, I looked into why the two unit tests for handling bad certificates
in
http_network_transaction_unittest.cc passed on Mac before I checked in this CL.
It's because they're using mock SSL sockets!

I am going to add unit tests for handling bad certificates that use real SSL
sockets.
I have a CL at http://codereview.chromium.org/170016.  Thank you for keeping
me honest.

Powered by Google App Engine
This is Rietveld 408576698