Chromium Code Reviews| 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 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 135 WebContents* embedder_web_contents) {} | 135 WebContents* embedder_web_contents) {} |
| 136 | 136 |
| 137 // Notifies that a RenderProcessHost has been created. This is called before | 137 // Notifies that a RenderProcessHost has been created. This is called before |
| 138 // the content layer adds its own BrowserMessageFilters, so that the | 138 // the content layer adds its own BrowserMessageFilters, so that the |
| 139 // embedder's IPC filters have priority. | 139 // embedder's IPC filters have priority. |
| 140 virtual void RenderProcessHostCreated(RenderProcessHost* host) {} | 140 virtual void RenderProcessHostCreated(RenderProcessHost* host) {} |
| 141 | 141 |
| 142 // Notifies that a BrowserChildProcessHost has been created. | 142 // Notifies that a BrowserChildProcessHost has been created. |
| 143 virtual void BrowserChildProcessHostCreated(BrowserChildProcessHost* host) {} | 143 virtual void BrowserChildProcessHostCreated(BrowserChildProcessHost* host) {} |
| 144 | 144 |
| 145 | |
|
Charlie Reis
2013/05/01 16:50:06
nit: Remove extra blank line.
Shishir
2013/05/01 19:11:11
Done.
| |
| 146 // Determines whether a navigation from |current_instance| to |url| would be a | |
| 147 // valid entry point to a "privileged site," based on whether it | |
| 148 // |is_renderer_initiated|. A privileged site requires careful process | |
| 149 // isolation to ensure its privileges do not leak, and it can only be entered | |
| 150 // via known navigation paths. | |
| 151 // | |
| 152 // If this is a valid entry to a privileged site, this function should rewrite | |
| 153 // the origin of |url| with a non-http(s) origin that represents the | |
| 154 // privileged site. This will distinguish the resulting SiteInstance from | |
| 155 // other SiteInstances in the process model. | |
| 156 virtual GURL GetPossiblyPrivilegedURL( | |
| 157 content::BrowserContext* browser_context, | |
| 158 const GURL& url, | |
| 159 bool is_renderer_initiated, | |
| 160 SiteInstance* current_instance); | |
| 161 | |
| 145 // Get the effective URL for the given actual URL, to allow an embedder to | 162 // Get the effective URL for the given actual URL, to allow an embedder to |
| 146 // group different url schemes in the same SiteInstance. | 163 // group different url schemes in the same SiteInstance. |
| 147 virtual GURL GetEffectiveURL(BrowserContext* browser_context, | 164 virtual GURL GetEffectiveURL(BrowserContext* browser_context, |
| 148 const GURL& url); | 165 const GURL& url); |
| 149 | 166 |
| 150 // Returns whether all instances of the specified effective URL should be | 167 // Returns whether all instances of the specified effective URL should be |
| 151 // rendered by the same process, rather than using process-per-site-instance. | 168 // rendered by the same process, rather than using process-per-site-instance. |
| 152 virtual bool ShouldUseProcessPerSite(BrowserContext* browser_context, | 169 virtual bool ShouldUseProcessPerSite(BrowserContext* browser_context, |
| 153 const GURL& effective_url); | 170 const GURL& effective_url); |
| 154 | 171 |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 532 // This is called on a worker thread. | 549 // This is called on a worker thread. |
| 533 virtual | 550 virtual |
| 534 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( | 551 crypto::CryptoModuleBlockingPasswordDelegate* GetCryptoPasswordDelegate( |
| 535 const GURL& url); | 552 const GURL& url); |
| 536 #endif | 553 #endif |
| 537 }; | 554 }; |
| 538 | 555 |
| 539 } // namespace content | 556 } // namespace content |
| 540 | 557 |
| 541 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 558 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |