Skip to content

Commit 2d56f31

Browse files
committed
Remove frame-ancestors CSP to allow embedding via iframe
1 parent 3377d1a commit 2d56f31

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed

res/_headers

+1-4
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@
77
# Protection for versions that do not support CSP yet.
88
X-XSS-Protection: 1; mode=block
99

10-
# Do not allow being embedded in a frame.
11-
X-Frame-Options: SAMEORIGIN
12-
1310
# Do not give the referrer for external navigations.
1411
Referrer-Policy: same-origin
1512

@@ -25,7 +22,7 @@
2522
# 7. `frame-ancestors` is the same purpose as `X-Frame-Options` above.
2623
# 8. `form-action`prevents forms, we don't need this.`
2724
# 9. `frame-src` allows the embedding of YouTube videos in the docs.
28-
Content-Security-Policy: default-src 'self'; script-src 'self' 'wasm-unsafe-eval'; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com; font-src 'self' https://fonts.gstatic.com; img-src http: https: data:; object-src 'none'; connect-src *; frame-ancestors 'self'; form-action 'none'; frame-src www.youtube-nocookie.com
25+
Content-Security-Policy: default-src 'self'; script-src 'self' 'wasm-unsafe-eval'; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com; font-src 'self' https://fonts.gstatic.com; img-src http: https: data:; object-src 'none'; connect-src *; form-action 'none'; frame-src www.youtube-nocookie.com
2926

3027
# Set the correct MIME type for WebAssembly modules.
3128
/*.wasm

server.js

-2
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ const serverConfig = {
4747
// /!\ Don't forget to keep it sync-ed with the headers here /!\
4848
'X-Content-Type-Options': 'nosniff',
4949
'X-XSS-Protection': '1; mode=block',
50-
'X-Frame-Options': 'SAMEORIGIN',
5150
'Referrer-Policy': 'same-origin',
5251
'Content-Security-Policy': oneLine`
5352
default-src 'self';
@@ -59,7 +58,6 @@ const serverConfig = {
5958
img-src http: https: data:;
6059
object-src 'none';
6160
connect-src *;
62-
frame-ancestors 'self';
6361
form-action 'none'
6462
`,
6563
},

0 commit comments

Comments
 (0)