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

Side by Side Diff: chrome/browser/ssl/security_state_tab_helper.cc

Issue 2616553002: Remove obsolete SHA-1 UX elements (Closed)
Patch Set: Final nits Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/ssl/security_state_tab_helper_browser_tests.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ssl/security_state_tab_helper.h" 5 #include "chrome/browser/ssl/security_state_tab_helper.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 } 194 }
195 195
196 std::unique_ptr<security_state::VisibleSecurityState> 196 std::unique_ptr<security_state::VisibleSecurityState>
197 SecurityStateTabHelper::GetVisibleSecurityState() const { 197 SecurityStateTabHelper::GetVisibleSecurityState() const {
198 auto state = security_state::GetVisibleSecurityState(web_contents()); 198 auto state = security_state::GetVisibleSecurityState(web_contents());
199 199
200 // Malware status might already be known even if connection security 200 // Malware status might already be known even if connection security
201 // information is still being initialized, thus no need to check for that. 201 // information is still being initialized, thus no need to check for that.
202 state->malicious_content_status = GetMaliciousContentStatus(); 202 state->malicious_content_status = GetMaliciousContentStatus();
203 203
204 // If the chain contains SHA1, populate the display policy field.
205 // In M56, we want to display a Neutral security state if the SHA1
206 // certificate was not blocked because the kCertEnableSha1LocalAnchors
207 // policy has been set.
208 // TODO(elawrence): remove this in M57, https://crbug.com/676826
209 if (state->cert_status & net::CERT_STATUS_SHA1_SIGNATURE_PRESENT) {
210 state->display_sha1_from_local_anchors_as_neutral =
211 g_browser_process->local_state()->GetBoolean(
212 ssl_config::prefs::kCertEnableSha1LocalAnchors);
213 }
214
215 return state; 204 return state;
216 } 205 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ssl/security_state_tab_helper_browser_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698