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

Issue 3565006: Decouples certificates viewers from NSS to prepare support for OpenSSL. (Closed)

Created:
10 years, 2 months ago by bulach
Modified:
9 years, 7 months ago
Reviewers:
joth, mattm
CC:
chromium-reviews, cbentzel+watch_chromium.org, darin-cc_chromium.org, ben+cc_chromium.org, Ryan Sleevi, wtc
Visibility:
Public.

Description

Decouples certificates viewers from NSS to prepare support for OpenSSL. This change is a pre-requisite for http://codereview.chromium.org/3529008/show There are no functional changes, it's only refactoring existing code. BUG=None TEST=Go to an https:// page and check the certificate info. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=61944

Patch Set 1 : Patch #

Patch Set 2 : Patch #

Total comments: 44

Patch Set 3 : Comments #

Total comments: 2

Patch Set 4 : More comments #

Total comments: 8

Patch Set 5 : Comments / ProcessIDN #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1031 lines, -989 lines) Patch
M build/common.gypi View 1 2 2 chunks +6 lines, -1 line 0 comments Download
M chrome/browser/certificate_manager_model.cc View 1 2 3 4 4 chunks +12 lines, -47 lines 0 comments Download
M chrome/browser/gtk/certificate_dialogs.h View 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/gtk/certificate_dialogs.cc View 1 2 3 4 8 chunks +20 lines, -112 lines 0 comments Download
D chrome/browser/gtk/certificate_manager.h View 1 chunk +0 lines, -38 lines 0 comments Download
M chrome/browser/gtk/certificate_manager.cc View 1 1 chunk +0 lines, -514 lines 0 comments Download
M chrome/browser/gtk/certificate_viewer.h View 1 chunk +3 lines, -3 lines 0 comments Download
M chrome/browser/gtk/certificate_viewer.cc View 1 2 27 chunks +90 lines, -134 lines 0 comments Download
M chrome/browser/gtk/ssl_client_certificate_selector.cc View 1 2 6 chunks +42 lines, -70 lines 0 comments Download
M chrome/browser/prefs/browser_prefs.cc View 2 3 2 chunks +0 lines, -2 lines 0 comments Download
M chrome/chrome_browser.gypi View 2 3 4 1 chunk +0 lines, -2 lines 0 comments Download
M chrome/chrome_common.gypi View 2 3 4 2 chunks +31 lines, -0 lines 0 comments Download
A chrome/common/net/DEPS View 1 chunk +4 lines, -0 lines 0 comments Download
A chrome/common/net/x509_certificate_model.h View 2 3 4 1 chunk +128 lines, -0 lines 0 comments Download
A chrome/common/net/x509_certificate_model.cc View 1 chunk +53 lines, -0 lines 0 comments Download
A chrome/common/net/x509_certificate_model_nss.cc View 2 3 4 1 chunk +381 lines, -0 lines 0 comments Download
A chrome/common/net/x509_certificate_model_openssl.cc View 2 3 4 1 chunk +203 lines, -0 lines 0 comments Download
M chrome/third_party/mozilla_security_manager/nsNSSCertHelper.h View 1 chunk +0 lines, -5 lines 0 comments Download
M chrome/third_party/mozilla_security_manager/nsNSSCertHelper.cpp View 4 chunks +3 lines, -39 lines 0 comments Download
M net/base/cert_database.h View 1 2 3 4 1 chunk +1 line, -17 lines 0 comments Download
A net/base/cert_type.h View 1 2 1 chunk +30 lines, -0 lines 0 comments Download
M net/net.gyp View 1 2 3 4 chunks +21 lines, -2 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
bulach
Matt: since I'm removing a few TODOs on your name, I thought you may want ...
10 years, 2 months ago (2010-10-04 19:59:11 UTC) #1
mattm
Still looking over this, but one note, you could just delete chrome/browser/gtk/certificate_manager.cc, it's being replaced ...
10 years, 2 months ago (2010-10-04 21:08:07 UTC) #2
bulach
thanks for the heads up, Matt! removed certificate_manager.cc and associated functions in the model. I ...
10 years, 2 months ago (2010-10-05 11:30:04 UTC) #3
joth
Thanks for taking this on. http://codereview.chromium.org/3565006/diff/9001/10007 File chrome/browser/gtk/certificate_viewer.cc (right): http://codereview.chromium.org/3565006/diff/9001/10007#newcode153 chrome/browser/gtk/certificate_viewer.cc:153: //psm::RegisterDynamicOids(); remove? http://codereview.chromium.org/3565006/diff/9001/10009 File ...
10 years, 2 months ago (2010-10-05 13:06:06 UTC) #4
bulach
thanks joth! all comments addressed / replied, another look please? http://codereview.chromium.org/3565006/diff/9001/10007 File chrome/browser/gtk/certificate_viewer.cc (right): http://codereview.chromium.org/3565006/diff/9001/10007#newcode153 ...
10 years, 2 months ago (2010-10-05 15:20:24 UTC) #5
joth
On 5 October 2010 16:20, <bulach@chromium.org> wrote: > thanks joth! all comments addressed / replied, ...
10 years, 2 months ago (2010-10-05 16:17:34 UTC) #6
joth
http://codereview.chromium.org/3565006/diff/22001/23014 File chrome/common/net/x509_certificate_model.h (right): http://codereview.chromium.org/3565006/diff/22001/23014#newcode75 chrome/common/net/x509_certificate_model.h:75: const std::vector<scoped_refptr<net::X509Certificate> >& certs, nit: const CertificateList& certs
10 years, 2 months ago (2010-10-05 20:55:52 UTC) #7
joth
[wtc, rsleevi: moved to cc for clarity, feel free to add yourself back to reviewer ...
10 years, 2 months ago (2010-10-07 20:01:42 UTC) #8
joth
http://codereview.chromium.org/3565006/diff/10020/29 File chrome/common/net/x509_certificate_model.h (right): http://codereview.chromium.org/3565006/diff/10020/29#newcode76 chrome/common/net/x509_certificate_model.h:76: const net::CertificateList& certs, nit: now it will fit on ...
10 years, 2 months ago (2010-10-07 20:04:17 UTC) #9
mattm
lgtm with a few comments http://codereview.chromium.org/3565006/diff/10020/18 File chrome/browser/gtk/certificate_dialogs.cc (right): http://codereview.chromium.org/3565006/diff/10020/18#newcode8 chrome/browser/gtk/certificate_dialogs.cc:8: // x509_certificate_nss. Could remove ...
10 years, 2 months ago (2010-10-07 20:30:08 UTC) #10
bulach
10 years, 2 months ago (2010-10-08 09:25:15 UTC) #11
thanks all!

comments addressed, will land as soon as the try-servers are green.

http://codereview.chromium.org/3565006/diff/22001/23014
File chrome/common/net/x509_certificate_model.h (right):

http://codereview.chromium.org/3565006/diff/22001/23014#newcode75
chrome/common/net/x509_certificate_model.h:75: const
std::vector<scoped_refptr<net::X509Certificate> >& certs,
On 2010/10/05 20:55:52, joth wrote:
> nit: const CertificateList& certs
> 
> 

Done.

http://codereview.chromium.org/3565006/diff/10020/18
File chrome/browser/gtk/certificate_dialogs.cc (right):

http://codereview.chromium.org/3565006/diff/10020/18#newcode8
chrome/browser/gtk/certificate_dialogs.cc:8: // x509_certificate_nss.
On 2010/10/07 20:30:08, mattm wrote:
> Could remove this TODO now.

:) done

http://codereview.chromium.org/3565006/diff/10020/29
File chrome/common/net/x509_certificate_model.h (right):

http://codereview.chromium.org/3565006/diff/10020/29#newcode76
chrome/common/net/x509_certificate_model.h:76: const net::CertificateList&
certs,
On 2010/10/07 20:04:17, joth wrote:
> nit: now it will fit on the previous line

Done.

http://codereview.chromium.org/3565006/diff/10020/30
File chrome/common/net/x509_certificate_model_nss.cc (right):

http://codereview.chromium.org/3565006/diff/10020/30#newcode280
chrome/common/net/x509_certificate_model_nss.cc:280: return
psm::ProcessIDN(input);
On 2010/10/07 20:30:08, mattm wrote:
> Actually ProcessIDN could be moved out of
> chrome/third_party/mozilla_security_manager/nsNSSCertHelper.cpp to some shared
> place.  It doesn't depend on any NSS stuff, and isn't based on mozilla code. 
I
> don't know why I put it there :/
> 
> Could just put a TODO if you don't want to do it in this CL.

good point!  I added a new file, x509_certificate_model.cc, and moved ProcessIDN
in there. it's in chrome/common/net, but nsNSSCertCertHelper already depends on
strings, so hopefully DEPS won't complain.

http://codereview.chromium.org/3565006/diff/10020/30#newcode304
chrome/common/net/x509_certificate_model_nss.cc:304: cert_handle->derCert.len);
On 2010/10/07 20:30:08, mattm wrote:
> indentation

Done.

Powered by Google App Engine
This is Rietveld 408576698