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

Unified Diff: content/browser/renderer_host/render_process_host_impl.h

Issue 10837230: Move StoragePartition into content/public and remove BrowserContext::GetDOMStorageContext(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove DISALLOW_COPY_AND_ASSIGN, and change RPH::CreateMessageFilters() to not suddenly isolate all… Created 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/render_process_host_impl.h
diff --git a/content/browser/renderer_host/render_process_host_impl.h b/content/browser/renderer_host/render_process_host_impl.h
index 1d568addb6c475004b3ff733919ff303bc5de25d..3876b8aed287947e2decd7e3bf361a9206a918b5 100644
--- a/content/browser/renderer_host/render_process_host_impl.h
+++ b/content/browser/renderer_host/render_process_host_impl.h
@@ -26,6 +26,7 @@ class RendererMainThread;
class RenderWidgetHelper;
class RenderWidgetHost;
class RenderWidgetHostImpl;
+class StoragePartitionImpl;
// Implements a concrete RenderProcessHost for the browser process for talking
// to actual renderer processes (as opposed to mocks).
@@ -41,11 +42,18 @@ class RenderWidgetHostImpl;
// keeps a list of RenderView (renderer) and WebContentsImpl (browser) which
// are correlated with IDs. This way, the Views and the corresponding ViewHosts
// communicate through the two process objects.
+//
+// A RenderProcessHost is also associated with one and only one
+// StoragePartition. This allows us to implement strong storage isolation
+// because all the IPCs from the RenderViews (renderer) will only ever be able
+// to access the partition they are assigned to.
class CONTENT_EXPORT RenderProcessHostImpl
: public RenderProcessHost,
public ChildProcessLauncher::Client {
public:
- RenderProcessHostImpl(BrowserContext* browser_context, bool is_guest);
+ RenderProcessHostImpl(BrowserContext* browser_context,
+ StoragePartitionImpl* storage_partition_impl,
+ bool is_guest);
virtual ~RenderProcessHostImpl();
// RenderProcessHost implementation (public portion).
@@ -259,6 +267,9 @@ class CONTENT_EXPORT RenderProcessHostImpl
BrowserContext* browser_context_;
+ // Owned by |browser_context_|.
+ StoragePartitionImpl* storage_partition_impl_;
+
// True if the process can be shut down suddenly. If this is true, then we're
// sure that all the RenderViews in the process can be shutdown suddenly. If
// it's false, then specific RenderViews might still be allowed to be shutdown
« no previous file with comments | « content/browser/renderer_host/render_message_filter.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698