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

Unified Diff: chrome/common/extensions/csp_handler.h

Issue 83843002: Move ManifestHandlers to extensions/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: s/handler/info Created 7 years, 1 month 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 | « chrome/common/extensions/chrome_manifest_handlers.cc ('k') | chrome/common/extensions/csp_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/csp_handler.h
diff --git a/chrome/common/extensions/csp_handler.h b/chrome/common/extensions/csp_handler.h
deleted file mode 100644
index 9e79f9d92ab52ed78fa90416e6d7e2c496d5dba5..0000000000000000000000000000000000000000
--- a/chrome/common/extensions/csp_handler.h
+++ /dev/null
@@ -1,54 +0,0 @@
-// Copyright (c) 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_COMMON_EXTENSIONS_CSP_HANDLER_H_
-#define CHROME_COMMON_EXTENSIONS_CSP_HANDLER_H_
-
-#include <string>
-
-#include "extensions/common/extension.h"
-#include "extensions/common/manifest_handler.h"
-
-namespace extensions {
-
-// A structure to hold the Content-Security-Policy information.
-struct CSPInfo : public Extension::ManifestData {
- explicit CSPInfo(const std::string& security_policy);
- virtual ~CSPInfo();
-
- // The Content-Security-Policy for an extension. Extensions can use
- // Content-Security-Policies to mitigate cross-site scripting and other
- // vulnerabilities.
- std::string content_security_policy;
-
- static const std::string& GetContentSecurityPolicy(
- const Extension* extension);
-
- // Returns the Content Security Policy that the specified resource should be
- // served with.
- static const std::string& GetResourceContentSecurityPolicy(
- const Extension* extension,
- const std::string& relative_path);
-};
-
-// Parses "content_security_policy" and "app.content_security_policy" keys.
-class CSPHandler : public ManifestHandler {
- public:
- explicit CSPHandler(bool is_platform_app);
- virtual ~CSPHandler();
-
- virtual bool Parse(Extension* extension, string16* error) OVERRIDE;
- virtual bool AlwaysParseForType(Manifest::Type type) const OVERRIDE;
-
- private:
- virtual const std::vector<std::string> Keys() const OVERRIDE;
-
- bool is_platform_app_;
-
- DISALLOW_COPY_AND_ASSIGN(CSPHandler);
-};
-
-} // namespace extensions
-
-#endif // CHROME_COMMON_EXTENSIONS_CSP_HANDLER_H_
« no previous file with comments | « chrome/common/extensions/chrome_manifest_handlers.cc ('k') | chrome/common/extensions/csp_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698