Skip to content

Commit 5670020

Browse files
committed
Add Vercel configuration file with security headers
1 parent a45b187 commit 5670020

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

vercel.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"$schema": "https://openapi.vercel.sh/vercel.json",
3+
"fluid": true,
4+
"framework": "vite",
5+
"headers": [
6+
{
7+
"source": "/(.*)",
8+
"headers": [
9+
{
10+
"key": "X-Frame-Options",
11+
"value": "DENY"
12+
},
13+
{
14+
"key": "X-Content-Type-Options",
15+
"value": "nosniff"
16+
},
17+
{
18+
"key": "Referrer-Policy",
19+
"value": "no-referrer"
20+
},
21+
{
22+
"key": "Permissions-Policy",
23+
"value": "autoplay=(self), fullscreen=(self), picture-in-picture=(), geolocation=(), microphone=(), camera=(), display-capture=(), screen-wake-lock=(), usb=(), serial=(), bluetooth=(), hid=(), midi=(), payment=(), speaker-selection=(), accelerometer=(), gyroscope=(), magnetometer=(), clipboard-read=(), clipboard-write=(), web-share=(), idle-detection=(), document-domain=(), encrypted-media=(), storage-access=(), attribution-reporting=(), browsing-topics=(), run-ad-auction=(), join-ad-interest-group=(), publickey-credentials-get=(), xr-spatial-tracking=(), gamepad=(), sync-xhr=(), local-fonts=(), otp-credentials=(), window-management=()"
24+
},
25+
{
26+
"key": "Cross-Origin-Resource-Policy",
27+
"value": "same-origin"
28+
},
29+
{
30+
"key": "Strict-Transport-Security",
31+
"value": "max-age=63072000; includeSubDomains; preload"
32+
},
33+
{
34+
"key": "Content-Security-Policy",
35+
"value": "default-src 'self'; base-uri 'none'; object-src 'none'; frame-ancestors 'none'; frame-src 'none'; form-action 'none'; navigate-to 'self'; manifest-src 'self'; worker-src 'self'; connect-src 'self'; img-src 'self' data: blob:; font-src 'self' data:; style-src 'self'; script-src 'self' 'wasm-unsafe-eval'; media-src 'self' blob:; prefetch-src 'self'; upgrade-insecure-requests"
36+
}
37+
]
38+
}
39+
]
40+
}

0 commit comments

Comments
 (0)