Skip to content

Commit 845283c

Browse files
SenrianJtrust
andauthored
fix: use SetEnv CSP_PROJECT_DOMAINS instead of overriding CSP header (#815)
Follow Apache Infra standard CSP handling per https://infra.apache.org/tools/csp.html The Content-Security-Policy header must not be overridden directly. Instead, use SetEnv CSP_PROJECT_DOMAINS to add project-specific domains to the default Apache CSP base policy. Co-authored-by: Zhang Juntao <zhangjuntao@apache.org>
1 parent 676041e commit 845283c

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

.htaccess

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
ErrorDocument 404 /404.html
22

3-
<IfModule mod_headers.c>
4-
Header set Content-Security-Policy "frame-src 'self' https://www.google.com https://app.netlify.com"
5-
</IfModule>
3+
# CSP permissions for apache.skywalking.apache.org - Adding third party services Google, Netlify. Approved per https://infra.apache.org/tools/csp.html
4+
SetEnv CSP_PROJECT_DOMAINS "https://www.google.com https://app.netlify.com"

0 commit comments

Comments
 (0)