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

Unified Diff: chrome/renderer/extensions/extension_process_bindings.cc

Issue 293021: Introduce WebSecurityPolicy for security related methods (Closed)
Patch Set: socket needs weburl import Created 11 years, 2 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
« no previous file with comments | « no previous file | chrome/renderer/render_thread.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/extensions/extension_process_bindings.cc
diff --git a/chrome/renderer/extensions/extension_process_bindings.cc b/chrome/renderer/extensions/extension_process_bindings.cc
index 50f596e0c0121d1c87ca6b15c9c2e38321403a58..9641c23018437c872c68f6e6ab22d813058b0bbe 100644
--- a/chrome/renderer/extensions/extension_process_bindings.cc
+++ b/chrome/renderer/extensions/extension_process_bindings.cc
@@ -27,6 +27,7 @@
#include "webkit/api/public/WebFrame.h"
#include "webkit/api/public/WebURL.h"
#include "webkit/api/public/WebKit.h"
+#include "webkit/api/public/WebSecurityPolicy.h"
using bindings_utils::GetStringResource;
using bindings_utils::ContextInfo;
@@ -37,6 +38,7 @@ using bindings_utils::PendingRequest;
using bindings_utils::PendingRequestMap;
using bindings_utils::ExtensionBase;
using WebKit::WebFrame;
+using WebKit::WebSecurityPolicy;
using WebKit::WebView;
namespace {
@@ -545,7 +547,7 @@ void ExtensionProcessBindings::SetHostPermissions(
const GURL& extension_url,
const std::vector<URLPattern>& permissions) {
for (size_t i = 0; i < permissions.size(); ++i) {
- WebKit::whiteListAccessFromOrigin(
+ WebSecurityPolicy::whiteListAccessFromOrigin(
extension_url,
WebKit::WebString::fromUTF8(permissions[i].scheme()),
WebKit::WebString::fromUTF8(permissions[i].host()),
« no previous file with comments | « no previous file | chrome/renderer/render_thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698