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

Unified Diff: extensions/common/csp_validator_unittest.cc

Issue 673183003: Allow *.googleapis.com to be used in CSP (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
« extensions/common/csp_validator.cc ('K') | « extensions/common/csp_validator.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/csp_validator_unittest.cc
diff --git a/extensions/common/csp_validator_unittest.cc b/extensions/common/csp_validator_unittest.cc
index 727a0683c4178743f6082ecf0d03b46e6040b027..55f6fe93fe3859f21570a2007b147cc726361c0c 100644
--- a/extensions/common/csp_validator_unittest.cc
+++ b/extensions/common/csp_validator_unittest.cc
@@ -162,6 +162,13 @@ TEST(ExtensionCSPValidator, IsSecure) {
EXPECT_FALSE(ContentSecurityPolicyIsSecure(
"default-src 'self' filesystem:http://example.com/XXX",
Manifest::TYPE_EXTENSION));
+
+ EXPECT_TRUE(ContentSecurityPolicyIsSecure(
+ "default-src 'self' https://*.googleapis.com", Manifest::TYPE_EXTENSION));
+ EXPECT_TRUE(ContentSecurityPolicyIsSecure(
+ "default-src 'self' https://x.googleapis.com", Manifest::TYPE_EXTENSION));
+ EXPECT_TRUE(ContentSecurityPolicyIsSecure(
+ "default-src 'self' https://s3.amazonaws.com", Manifest::TYPE_EXTENSION));
not at google - send to devlin 2014/10/24 22:16:52 Isn't s3.amazonaws.com considered secure either wa
robwu 2014/10/24 22:34:08 You're right, I've removed the amazonaws.com excep
}
TEST(ExtensionCSPValidator, IsSandboxed) {
« extensions/common/csp_validator.cc ('K') | « extensions/common/csp_validator.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698