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

Side by Side Diff: chrome/browser/extensions/api/web_request/web_request_permissions.h

Issue 10831008: Refactor and fix declarative webRequest API permissions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed license headers 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_EXTENSIONS_API_WEB_REQUEST_WEB_REQUEST_PERMISSIONS_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_WEB_REQUEST_WEB_REQUEST_PERMISSIONS_H_
7
8 #include <map>
9 #include <string>
10
11 #include "base/basictypes.h"
12
13 class ExtensionInfoMap;
14 class GURL;
15
16 namespace net {
17 class URLRequest;
18 }
19
20 // This class is used to test whether extensions may modify web requests.
21 class WebRequestPermissions {
22 public:
23 // Returns true if the request shall not be reported to extensions.
24 static bool HideRequest(const net::URLRequest* request);
25
26 static bool CanExtensionAccessURL(const ExtensionInfoMap* extension_info_map,
27 const std::string& extension_id,
28 const GURL& url,
29 bool crosses_incognito,
30 bool enforce_host_permissions);
31
32 private:
33 DISALLOW_IMPLICIT_CONSTRUCTORS(WebRequestPermissions);
34 };
35
36 #endif // CHROME_BROWSER_EXTENSIONS_API_WEB_REQUEST_WEB_REQUEST_PERMISSIONS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698