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

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

Issue 376333003: Find reasons for the SSL common name invalid error. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed Comments Created 6 years, 4 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/ssl_error_classification.h » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ssl_blocking_page.h" 5 #include "chrome/browser/ssl/ssl_blocking_page.h"
6 6
7 #include "base/build_time.h" 7 #include "base/build_time.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/i18n/rtl.h" 9 #include "base/i18n/rtl.h"
10 #include "base/i18n/time_formatting.h" 10 #include "base/i18n/time_formatting.h"
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 HistoryService* history_service = HistoryServiceFactory::GetForProfile( 304 HistoryService* history_service = HistoryServiceFactory::GetForProfile(
305 profile, Profile::EXPLICIT_ACCESS); 305 profile, Profile::EXPLICIT_ACCESS);
306 if (history_service) { 306 if (history_service) {
307 history_service->GetVisibleVisitCountToHost( 307 history_service->GetVisibleVisitCountToHost(
308 request_url_, 308 request_url_,
309 base::Bind(&SSLBlockingPage::OnGotHistoryCount, 309 base::Bind(&SSLBlockingPage::OnGotHistoryCount,
310 base::Unretained(this)), 310 base::Unretained(this)),
311 &request_tracker_); 311 &request_tracker_);
312 } 312 }
313 } 313 }
314 if (SSLErrorInfo::NetErrorToErrorType(cert_error_) == 314
315 SSLErrorInfo::CERT_DATE_INVALID) { 315 SSLErrorClassification ssl_error_classification(
316 SSLErrorClassification::RecordUMAStatistics(overridable_ && 316 base::Time::NowFromSystemTime(),
317 !strict_enforcement_); 317 request_url_,
318 } 318 *ssl_info_.cert.get());
319 ssl_error_classification.RecordUMAStatistics(
320 overridable_ && !strict_enforcement_, cert_error_);
319 321
320 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION) 322 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION)
321 CaptivePortalService* captive_portal_service = 323 CaptivePortalService* captive_portal_service =
322 CaptivePortalServiceFactory::GetForProfile(profile); 324 CaptivePortalServiceFactory::GetForProfile(profile);
323 captive_portal_detection_enabled_ = captive_portal_service ->enabled(); 325 captive_portal_detection_enabled_ = captive_portal_service ->enabled();
324 captive_portal_service ->DetectCaptivePortal(); 326 captive_portal_service ->DetectCaptivePortal();
325 registrar_.Add(this, 327 registrar_.Add(this,
326 chrome::NOTIFICATION_CAPTIVE_PORTAL_CHECK_RESULT, 328 chrome::NOTIFICATION_CAPTIVE_PORTAL_CHECK_RESULT,
327 content::Source<Profile>(profile)); 329 content::Source<Profile>(profile));
328 #endif 330 #endif
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 // sure we don't clear the captive portal flag, since the interstitial was 608 // sure we don't clear the captive portal flag, since the interstitial was
607 // potentially caused by the captive portal. 609 // potentially caused by the captive portal.
608 captive_portal_detected_ = captive_portal_detected_ || 610 captive_portal_detected_ = captive_portal_detected_ ||
609 (results->result == captive_portal::RESULT_BEHIND_CAPTIVE_PORTAL); 611 (results->result == captive_portal::RESULT_BEHIND_CAPTIVE_PORTAL);
610 // Also keep track of non-HTTP portals and error cases. 612 // Also keep track of non-HTTP portals and error cases.
611 captive_portal_no_response_ = captive_portal_no_response_ || 613 captive_portal_no_response_ = captive_portal_no_response_ ||
612 (results->result == captive_portal::RESULT_NO_RESPONSE); 614 (results->result == captive_portal::RESULT_NO_RESPONSE);
613 } 615 }
614 #endif 616 #endif
615 } 617 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ssl/ssl_error_classification.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698