summaryrefslogtreecommitdiffstats
path: root/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2019-01-07 13:13:34 +0100
committerRoeland Jago Douma <roeland@famdouma.nl>2019-01-07 15:07:06 +0100
commit64244e1a4fe3d287fc7764e9f64c65777384fff0 (patch)
tree8aa09a32117438094d7dfa22c4e183afd3974338 /tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
parentb820803cf1def6a6bfe398d1564dd0d9a3a3a9e0 (diff)
downloadnextcloud-server-64244e1a4fe3d287fc7764e9f64c65777384fff0.tar.gz
nextcloud-server-64244e1a4fe3d287fc7764e9f64c65777384fff0.zip
CSP: Allow fonts to be provided in data
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php')
-rw-r--r--tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php b/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
index 2a82e9c4878..e9045ddecd0 100644
--- a/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
+++ b/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
@@ -63,7 +63,7 @@ class ContentSecurityPolicyManagerTest extends \Test\TestCase {
$expected->addAllowedImageDomain('anotherdomain.de');
$expected->addAllowedImageDomain('example.org');
$expected->addAllowedChildSrcDomain('childdomain');
- $expectedStringPolicy = "default-src 'none';base-uri 'none';manifest-src 'self';script-src 'self' 'unsafe-inline' 'unsafe-eval';style-src 'self' 'unsafe-inline';img-src 'self' data: blob: anotherdomain.de example.org;font-src 'self' mydomain.com example.com anotherFontDomain;connect-src 'self';media-src 'self';child-src childdomain";
+ $expectedStringPolicy = "default-src 'none';base-uri 'none';manifest-src 'self';script-src 'self' 'unsafe-inline' 'unsafe-eval';style-src 'self' 'unsafe-inline';img-src 'self' data: blob: anotherdomain.de example.org;font-src 'self' data: mydomain.com example.com anotherFontDomain;connect-src 'self';media-src 'self';child-src childdomain";
$this->assertEquals($expected, $this->contentSecurityPolicyManager->getDefaultPolicy());
$this->assertSame($expectedStringPolicy, $this->contentSecurityPolicyManager->getDefaultPolicy()->buildPolicy());