hakurei.app/nginx/snippets/security-headers.conf
2020-04-01 08:47:16 -04:00

10 lines
1.8 KiB
Plaintext

add_header X-XSS-Protection "1; mode=block" always;
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;
add_header X-Content-Type-Options "nosniff" always;
add_header X-Frame-Options "DENY" always;
add_header Referrer-Policy "no-referrer" always;
add_header Expect-CT "enforce, max-age=63072000, report-uri=\"https://danielmicay.report-uri.com/r/d/ct/enforce\"" always;
add_header Public-Key-Pins "max-age=2592000; pin-sha256=\"YLh1dUR9y6Kja30RrAn7JKnbQG/uEtLMkBgFF2Fuihg=\"; pin-sha256=\"sRHdihwgkaib1P1gxX8HFszlD+7/gTfNvuAybgLPNis=\"; pin-sha256=\"Vjs8r4z+80wjNcr1YKepWQboSIRi63WsWXhIMN+eWys=\"; pin-sha256=\"C5+lpZ7tcVwmwQIMcRtPbsQtWLABXhQzejna0wHFr8M=\"; pin-sha256=\"mABt36m6Z2G6pnosx0K3dhXY+nUrZeZVWZlSW4GBZGs=\"; pin-sha256=\"v/9edLATMEdwyTJp0eXTft119lGXjZThpGSeX7t5Jv8=\"; pin-sha256=\"+f4CIotdnI56+v8CTfQvN88mYlQ1saQ1U68YvAwlotU=\"; pin-sha256=\"q3TMLLQkHOLGnFXKL1RytMd1Vr906gdK/ymgcBnk144=\"; pin-sha256=\"x3i8R25x59RNyo1LAunh4lGFvnIYXT5oTq2dOVgxTWU=\"; includeSubDomains" always;
add_header Content-Security-Policy "default-src 'none'; connect-src 'self' https://releases.grapheneos.org/; font-src 'self'; img-src 'self'; manifest-src 'self'; script-src 'self'; style-src 'self'; form-action 'none'; frame-ancestors 'none'; block-all-mixed-content; base-uri 'none'; report-uri https://danielmicay.report-uri.com/r/d/csp/enforce" always;
add_header Feature-Policy "accelerometer 'none'; ambient-light-sensor 'none'; autoplay 'none'; battery 'none'; camera 'none'; display-capture 'none'; document-domain 'none'; encrypted-media 'none'; fullscreen 'none'; geolocation 'none'; gyroscope 'none'; magnetometer 'none'; microphone 'none'; midi 'none'; payment 'none'; picture-in-picture 'none'; speaker 'none'; sync-xhr 'none'; usb 'none'; wake-lock 'none'; xr-spatial-tracking 'none'" always;