| Index: chrome/common/extensions/csp_handler.cc
|
| diff --git a/chrome/common/extensions/csp_handler.cc b/chrome/common/extensions/csp_handler.cc
|
| index 1ed5832a1577e10ab89239f00e2a54e612924c0d..978a86d20c69f21e3d17644d404543b88a730b1f 100644
|
| --- a/chrome/common/extensions/csp_handler.cc
|
| +++ b/chrome/common/extensions/csp_handler.cc
|
| @@ -10,6 +10,7 @@
|
| #include "base/values.h"
|
| #include "chrome/common/extensions/csp_validator.h"
|
| #include "chrome/common/extensions/extension_manifest_constants.h"
|
| +#include "chrome/common/extensions/manifest_handlers/sandboxed_page_info.h"
|
|
|
| namespace keys = extension_manifest_keys;
|
| namespace errors = extension_manifest_errors;
|
| @@ -60,6 +61,15 @@ const std::string& CSPInfo::GetContentSecurityPolicy(
|
| return csp_info ? csp_info->content_security_policy : EmptyString();
|
| }
|
|
|
| +// static
|
| +const std::string& CSPInfo::GetResourceContentSecurityPolicy(
|
| + const Extension* extension,
|
| + const std::string& relative_path) {
|
| + return SandboxedPageInfo::IsSandboxedPage(extension, relative_path) ?
|
| + SandboxedPageInfo::GetContentSecurityPolicy(extension) :
|
| + GetContentSecurityPolicy(extension);
|
| +}
|
| +
|
| CSPHandler::CSPHandler(bool is_platform_app)
|
| : is_platform_app_(is_platform_app) {
|
| }
|
|
|