OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/ui/webui/interstitials/interstitial_ui.h" | 5 #include "chrome/browser/ui/webui/interstitials/interstitial_ui.h" |
6 | 6 |
7 #include "base/atomic_sequence_num.h" | 7 #include "base/atomic_sequence_num.h" |
8 #include "base/strings/string_number_conversions.h" | 8 #include "base/strings/string_number_conversions.h" |
9 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 net::SSLInfo ssl_info; | 155 net::SSLInfo ssl_info; |
156 ssl_info.cert = ssl_info.unverified_cert = CreateFakeCert(); | 156 ssl_info.cert = ssl_info.unverified_cert = CreateFakeCert(); |
157 // This delegate doesn't create an interstitial. | 157 // This delegate doesn't create an interstitial. |
158 int options_mask = 0; | 158 int options_mask = 0; |
159 if (overridable) | 159 if (overridable) |
160 options_mask |= security_interstitials::SSLErrorUI::SOFT_OVERRIDE_ENABLED; | 160 options_mask |= security_interstitials::SSLErrorUI::SOFT_OVERRIDE_ENABLED; |
161 if (strict_enforcement) | 161 if (strict_enforcement) |
162 options_mask |= security_interstitials::SSLErrorUI::STRICT_ENFORCEMENT; | 162 options_mask |= security_interstitials::SSLErrorUI::STRICT_ENFORCEMENT; |
163 return SSLBlockingPage::Create( | 163 return SSLBlockingPage::Create( |
164 web_contents, cert_error, ssl_info, request_url, options_mask, | 164 web_contents, cert_error, ssl_info, request_url, options_mask, |
165 time_triggered_, nullptr, | 165 time_triggered_, nullptr, false /* is superfish */, |
166 base::Callback<void(content::CertificateRequestResultType)>()); | 166 base::Callback<void(content::CertificateRequestResultType)>()); |
167 } | 167 } |
168 | 168 |
169 BadClockBlockingPage* CreateBadClockBlockingPage( | 169 BadClockBlockingPage* CreateBadClockBlockingPage( |
170 content::WebContents* web_contents) { | 170 content::WebContents* web_contents) { |
171 // Set up a fake clock error. | 171 // Set up a fake clock error. |
172 int cert_error = net::ERR_CERT_DATE_INVALID; | 172 int cert_error = net::ERR_CERT_DATE_INVALID; |
173 GURL request_url("https://example.com"); | 173 GURL request_url("https://example.com"); |
174 bool overridable = false; | 174 bool overridable = false; |
175 bool strict_enforcement = false; | 175 bool strict_enforcement = false; |
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
482 } else if (reason_string == "not_signed_in") { | 482 } else if (reason_string == "not_signed_in") { |
483 reason = supervised_user_error_page::NOT_SIGNED_IN; | 483 reason = supervised_user_error_page::NOT_SIGNED_IN; |
484 } | 484 } |
485 } | 485 } |
486 | 486 |
487 return supervised_user_error_page::BuildHtml( | 487 return supervised_user_error_page::BuildHtml( |
488 allow_access_requests, profile_image_url, profile_image_url2, custodian, | 488 allow_access_requests, profile_image_url, profile_image_url2, custodian, |
489 custodian_email, second_custodian, second_custodian_email, | 489 custodian_email, second_custodian, second_custodian_email, |
490 is_child_account, reason, g_browser_process->GetApplicationLocale()); | 490 is_child_account, reason, g_browser_process->GetApplicationLocale()); |
491 } | 491 } |
OLD | NEW |