workers-site: update CSP [staging]

Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
Harsh Shandilya 2020-12-19 12:20:46 +05:30
parent 33809c89ab
commit 454086f350
1 changed files with 1 additions and 1 deletions

View File

@ -6,7 +6,7 @@ const GITHUB_URL = `https://github.com/${GITHUB_USERNAME}`
const APS_GITHUB_URL = `https://github.com/${APS_SLUG}`
const CSP_POLICY = "base-uri 'self'; connect-src 'self'; default-src 'self'; frame-ancestors 'none'; frame-src asciinema.org github.com platform.twitter.com; font-src 'self' fonts.gstatic.com; img-src 'self' data: gfycat.com imgur.com *.imgur.com syndication.twitter.com; object-src 'none'; script-src 'self' asciinema.org cdn.jsdelivr.net platform.twitter.com unpkg.com 'nonce-MZSWC5DVOJSS23TPNZRWKCQ='; style-src 'self' cdn.jsdelivr.net fonts.googleapis.com;";
const FEATURE_POLICY = "accelerometer 'none'; autoplay 'none';camera 'none';encrypted-media 'none'; geolocation 'none';gyroscope 'none';magnetometer 'none';microphone 'none';midi 'none';payment 'none';picture-in-picture 'none';sync-xhr 'none';usb 'none'"
const PERMISSIONS_POLICY = "accelerometer=() autoplay=() camera=() encrypted-media=() geolocation=() gyroscope=() magnetometer=() microphone=() midi=() payment=() picture-in-picture=() sync-xhr=() usb=()"
const PERMISSIONS_POLICY = "accelerometer=(), autoplay=(), camera=(), encrypted-media=(), geolocation=(), gyroscope=(), magnetometer=(), microphone=(), midi=(), payment=(), picture-in-picture=(), sync-xhr=(), usb=()"
export async function handleRequest(event: FetchEvent): Promise<Response> {
return redirectGitHub(event)