diff options
author | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-02 02:07:44 +0000 |
---|---|---|
committer | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-02 02:07:44 +0000 |
commit | c88d24f1f8aaf609db1fdcc06c3a4b5ca528c7ed (patch) | |
tree | 1bba1823b5277ee9f096e04ab2234bf8856ec500 /chrome/browser/ssl | |
parent | 76451fe7fbce667742dff671cad06cbd039f8296 (diff) | |
download | chromium_src-c88d24f1f8aaf609db1fdcc06c3a4b5ca528c7ed.zip chromium_src-c88d24f1f8aaf609db1fdcc06c3a4b5ca528c7ed.tar.gz chromium_src-c88d24f1f8aaf609db1fdcc06c3a4b5ca528c7ed.tar.bz2 |
Do not say the connection is not encrypted if security_bits
is -1 (unknown). Say nothing in that case.
If the description for the connection section is empty, omit
the connection section in the dialog.
R=finnur,jcivelli
BUG=53366,13049
TEST=Visit https://alioth.debian.org/. Bring up the Security
info dialog while Chrome is displaying the SSL certificate
error page. The security info dialog should not say "Your
connection to alioth.debian.org is not encrypted."
Review URL: http://codereview.chromium.org/3243008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@58302 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/ssl')
-rw-r--r-- | chrome/browser/ssl/ssl_manager.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/chrome/browser/ssl/ssl_manager.cc b/chrome/browser/ssl/ssl_manager.cc index 5b40cc8..39e90a4 100644 --- a/chrome/browser/ssl/ssl_manager.cc +++ b/chrome/browser/ssl/ssl_manager.cc @@ -75,12 +75,12 @@ bool SSLManager::DeserializeSecurityInfo(const std::string& state, int* cert_status, int* security_bits, int* ssl_connection_status) { - DCHECK(cert_id && cert_status && security_bits); + DCHECK(cert_id && cert_status && security_bits && ssl_connection_status); if (state.empty()) { // No SSL used. *cert_id = 0; *cert_status = 0; - *security_bits = -1; + *security_bits = 0; // Not encrypted. *ssl_connection_status = 0; return false; } @@ -139,7 +139,8 @@ void SSLManager::DidCommitProvisionalLoad( if (details->is_main_frame) { if (entry) { // Decode the security details. - int ssl_cert_id, ssl_cert_status, ssl_security_bits, ssl_connection_status; + int ssl_cert_id, ssl_cert_status, ssl_security_bits, + ssl_connection_status; DeserializeSecurityInfo(details->serialized_security_info, &ssl_cert_id, &ssl_cert_status, |