server { ... # ========== # HTTP security Headers # ========== # HSTS (ngx_http_headers_module is required) (15768000 seconds = 6 months) # add_header Strict-Transport-Security "max-age=31536000" always; add_header X-Frame-Options "SAMEORIGIN" always; add_header X-XSS-Protection "1; mode=block" always; add_header X-Content-Type-Options nosniff always; add_header Referrer-Policy "strict-origin"; # - Geteiltes Dokument öffnen # # # Add Etherpad-Lite host to frame-src, so frame-src becomes: # # # # #frame-src 'self' https:// https://www.youtube.com ; # # # # i.e. etherpad-litehost = epad-01.oopen.de # # # frame-src 'self' https://epad-01.oopen.de https://www.youtube.com ; # # # - YouTube-Video teilen # # # Add https://www.youtube.com to script-src, so script-src becomes: # # # script-src 'self' 'unsafe-inline' https://www.youtube.com ; # # # Add https://www.youtube.com to frame-src, so frame-src becomes: # # # frame-src 'self' https://meet-ep-pee7eiji-xein9aiy.oopen.de https://www.youtube.com ; # # # Add https://img.youtube.com to img-src, so img-src becomes: # img-src 'self' https://img.youtube.com # # # - Hintergrundschärfe aktivieren: # # # Add https://storage.googleapis.com to connect-src, so connect source becomes: # # # connect-src 'self' https://storage.googleapis.com; # # # Add blob: to script-src, so script-src becomes: # script-src 'self' 'unsafe-inline' https://www.youtube.com blob: # # Note! # Other directives (like worker-src, or child-src, or..) are falling back to 'default-src'. # add_header Content-Security-Policy "default-src 'none'; script-src 'self' 'unsafe-inline' https://www.youtube.com ; img-src 'self' https://img.youtube.com ; style-src 'self' 'unsafe-inline' ; font-src 'self'; frame-src 'self' https://epad-01.oopen.de https://www.youtube.com ; object-src 'none'; frame-ancestors 'none'; form-action 'self'; base-uri 'self'; connect-src 'self' https://storage.googleapis.com ; media-src 'self'"; # Etwas allgemeiner dafür auch etws unsicherer formuliert: # #add_header Content-Security-Policy "block-all-mixed-content ; default-src 'none'; script-src 'self' 'unsafe-inline' https: blob: ; img-src 'self' https: ; style-src 'self' 'unsafe-inline' ; font-src 'self'; frame-src 'self' https: ; object-src 'none'; frame-ancestors 'none'; form-action 'self'; base-uri 'self'; connect-src 'self' https: ; media-src 'self'"; add_header Permissions-Policy "geolocation=();midi=();notifications=();push=();sync-xhr=();microphone=();camera=();magnetometer=();gyroscope=();speaker=(self);vibrate=();fullscreen=(self);payment=();"; .. }