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

Side by Side Diff: components/security_state/content/content_utils.cc

Issue 2616553002: Remove obsolete SHA-1 UX elements (Closed)
Patch Set: Fixup WebsiteSettingsTest 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "components/security_state/content/content_utils.h" 5 #include "components/security_state/content/content_utils.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 // the page, and the embedder can choose to display HTTPS page as HTTP 224 // the page, and the embedder can choose to display HTTPS page as HTTP
225 // if it wants to (for example, displaying deprecated crypto 225 // if it wants to (for example, displaying deprecated crypto
226 // algorithms with the same UI treatment as HTTP pages). 226 // algorithms with the same UI treatment as HTTP pages).
227 security_style_explanations->scheme_is_cryptographic = 227 security_style_explanations->scheme_is_cryptographic =
228 security_info.scheme_is_cryptographic; 228 security_info.scheme_is_cryptographic;
229 if (!security_info.scheme_is_cryptographic) { 229 if (!security_info.scheme_is_cryptographic) {
230 return security_style; 230 return security_style;
231 } 231 }
232 232
233 if (security_info.sha1_deprecation_status == 233 if (security_info.sha1_deprecation_status ==
234 security_state::DEPRECATED_SHA1_MAJOR) { 234 security_state::DEPRECATED_SHA1) {
235 security_style_explanations->broken_explanations.push_back( 235 security_style_explanations->broken_explanations.push_back(
estark 2017/01/05 16:18:42 I might be getting myself confused, but I think th
236 content::SecurityStyleExplanation( 236 content::SecurityStyleExplanation(
237 l10n_util::GetStringUTF8(IDS_MAJOR_SHA1), 237 l10n_util::GetStringUTF8(IDS_SHA1),
238 l10n_util::GetStringUTF8(IDS_MAJOR_SHA1_DESCRIPTION), 238 l10n_util::GetStringUTF8(IDS_SHA1_DESCRIPTION),
239 !!security_info.certificate));
240 } else if (security_info.sha1_deprecation_status ==
241 security_state::DEPRECATED_SHA1_MINOR) {
242 security_style_explanations->unauthenticated_explanations.push_back(
243 content::SecurityStyleExplanation(
244 l10n_util::GetStringUTF8(IDS_MINOR_SHA1),
245 l10n_util::GetStringUTF8(IDS_MINOR_SHA1_DESCRIPTION),
246 !!security_info.certificate)); 239 !!security_info.certificate));
247 } 240 }
248 241
249 // Record the presence of mixed content (HTTP subresources on an HTTPS 242 // Record the presence of mixed content (HTTP subresources on an HTTPS
250 // page). 243 // page).
251 security_style_explanations->ran_mixed_content = 244 security_style_explanations->ran_mixed_content =
252 security_info.mixed_content_status == 245 security_info.mixed_content_status ==
253 security_state::CONTENT_STATUS_RAN || 246 security_state::CONTENT_STATUS_RAN ||
254 security_info.mixed_content_status == 247 security_info.mixed_content_status ==
255 security_state::CONTENT_STATUS_DISPLAYED_AND_RAN; 248 security_state::CONTENT_STATUS_DISPLAYED_AND_RAN;
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 security_style_explanations->info_explanations.push_back( 313 security_style_explanations->info_explanations.push_back(
321 content::SecurityStyleExplanation( 314 content::SecurityStyleExplanation(
322 "Public-Key Pinning Bypassed", 315 "Public-Key Pinning Bypassed",
323 "Public-key pinning was bypassed by a local root certificate.")); 316 "Public-key pinning was bypassed by a local root certificate."));
324 } 317 }
325 318
326 return security_style; 319 return security_style;
327 } 320 }
328 321
329 } // namespace security_state 322 } // namespace security_state
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698