| OLD | NEW |
| 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 <utility> | 5 #include <utility> |
| 6 | 6 |
| 7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/bind_helpers.h" | 9 #include "base/bind_helpers.h" |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 2958 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2969 protected: | 2969 protected: |
| 2970 // SecurityInterstitialIDNTest implementation | 2970 // SecurityInterstitialIDNTest implementation |
| 2971 SecurityInterstitialPage* CreateInterstitial( | 2971 SecurityInterstitialPage* CreateInterstitial( |
| 2972 content::WebContents* contents, | 2972 content::WebContents* contents, |
| 2973 const GURL& request_url) const override { | 2973 const GURL& request_url) const override { |
| 2974 net::SSLInfo ssl_info; | 2974 net::SSLInfo ssl_info; |
| 2975 ssl_info.cert = | 2975 ssl_info.cert = |
| 2976 net::ImportCertFromFile(net::GetTestCertsDirectory(), "ok_cert.pem"); | 2976 net::ImportCertFromFile(net::GetTestCertsDirectory(), "ok_cert.pem"); |
| 2977 return new SSLBlockingPage( | 2977 return new SSLBlockingPage( |
| 2978 contents, net::ERR_CERT_CONTAINS_ERRORS, ssl_info, request_url, 0, | 2978 contents, net::ERR_CERT_CONTAINS_ERRORS, ssl_info, request_url, 0, |
| 2979 base::Time::NowFromSystemTime(), nullptr, base::Callback<void(bool)>()); | 2979 base::Time::NowFromSystemTime(), nullptr, |
| 2980 base::Callback<void(content::CertificateRequestResultType)>()); |
| 2980 } | 2981 } |
| 2981 }; | 2982 }; |
| 2982 | 2983 |
| 2983 IN_PROC_BROWSER_TEST_F(SSLBlockingPageIDNTest, SSLBlockingPageDecodesIDN) { | 2984 IN_PROC_BROWSER_TEST_F(SSLBlockingPageIDNTest, SSLBlockingPageDecodesIDN) { |
| 2984 EXPECT_TRUE(VerifyIDNDecoded()); | 2985 EXPECT_TRUE(VerifyIDNDecoded()); |
| 2985 } | 2986 } |
| 2986 | 2987 |
| 2987 IN_PROC_BROWSER_TEST_F(CertVerifierBrowserTest, MockCertVerifierSmokeTest) { | 2988 IN_PROC_BROWSER_TEST_F(CertVerifierBrowserTest, MockCertVerifierSmokeTest) { |
| 2988 net::EmbeddedTestServer https_server(net::EmbeddedTestServer::TYPE_HTTPS); | 2989 net::EmbeddedTestServer https_server(net::EmbeddedTestServer::TYPE_HTTPS); |
| 2989 https_server.ServeFilesFromSourceDirectory(base::FilePath(kDocRoot)); | 2990 https_server.ServeFilesFromSourceDirectory(base::FilePath(kDocRoot)); |
| (...skipping 15 matching lines...) Expand all Loading... |
| 3005 | 3006 |
| 3006 // Visit a page over https that contains a frame with a redirect. | 3007 // Visit a page over https that contains a frame with a redirect. |
| 3007 | 3008 |
| 3008 // XMLHttpRequest insecure content in synchronous mode. | 3009 // XMLHttpRequest insecure content in synchronous mode. |
| 3009 | 3010 |
| 3010 // XMLHttpRequest insecure content in asynchronous mode. | 3011 // XMLHttpRequest insecure content in asynchronous mode. |
| 3011 | 3012 |
| 3012 // XMLHttpRequest over bad ssl in synchronous mode. | 3013 // XMLHttpRequest over bad ssl in synchronous mode. |
| 3013 | 3014 |
| 3014 // XMLHttpRequest over OK ssl in synchronous mode. | 3015 // XMLHttpRequest over OK ssl in synchronous mode. |
| OLD | NEW |