| Index: chrome/browser/chrome_security_exploit_browsertest.cc
|
| diff --git a/chrome/browser/chrome_security_exploit_browsertest.cc b/chrome/browser/chrome_security_exploit_browsertest.cc
|
| index 4486a02250c95ad72b08ca4bcf82febe928c4db1..00ad2b7d12dd1f3d48ffee6e1b950e86519d9613 100644
|
| --- a/chrome/browser/chrome_security_exploit_browsertest.cc
|
| +++ b/chrome/browser/chrome_security_exploit_browsertest.cc
|
| @@ -18,6 +18,7 @@
|
| #include "content/public/browser/web_contents_observer.h"
|
| #include "content/public/common/content_switches.h"
|
| #include "content/public/test/browser_test_utils.h"
|
| +#include "net/test/embedded_test_server/embedded_test_server.h"
|
|
|
| // The goal of these tests is to "simulate" exploited renderer processes, which
|
| // can send arbitrary IPC messages and confuse browser process internal state,
|
| @@ -31,19 +32,14 @@ class ChromeSecurityExploitBrowserTest : public InProcessBrowserTest {
|
| ~ChromeSecurityExploitBrowserTest() override {}
|
|
|
| void SetUpCommandLine(base::CommandLine* command_line) override {
|
| - ASSERT_TRUE(test_server()->Start());
|
| - net::SpawnedTestServer https_server(
|
| - net::SpawnedTestServer::TYPE_HTTPS,
|
| - net::SpawnedTestServer::kLocalhost,
|
| - base::FilePath(FILE_PATH_LITERAL("chrome/test/data")));
|
| - ASSERT_TRUE(https_server.Start());
|
| + ASSERT_TRUE(embedded_test_server()->Start());
|
|
|
| // Add a host resolver rule to map all outgoing requests to the test server.
|
| // This allows us to use "real" hostnames in URLs, which we can use to
|
| // create arbitrary SiteInstances.
|
| command_line->AppendSwitchASCII(
|
| switches::kHostResolverRules,
|
| - "MAP * " + test_server()->host_port_pair().ToString() +
|
| + "MAP * " + embedded_test_server()->host_port_pair().ToString() +
|
| ",EXCLUDE localhost");
|
|
|
| // Since we assume exploited renderer process, it can bypass the same origin
|
| @@ -59,7 +55,7 @@ IN_PROC_BROWSER_TEST_F(ChromeSecurityExploitBrowserTest,
|
| ChromeExtensionResources) {
|
| // Load a page that requests a chrome-extension:// image through XHR. We
|
| // expect this load to fail, as it is an illegal request.
|
| - GURL foo("http://foo.com/files/chrome_extension_resource.html");
|
| + GURL foo("http://foo.com/chrome_extension_resource.html");
|
|
|
| content::DOMMessageQueue msg_queue;
|
|
|
|
|