Our site sends six security headers on every response. Count them yourself:
curl -sI https://pub-trivia.app/faq
Enter fullscreen mode
Exit fullscreen mode
You get strict-transport-security , x-content-type-options , x-frame-options , referrer-policy , permissions-policy and x-dns-prefetch-control . You do not get a content-security-policy , because there is no CSP anywhere in the 79 pages in our sitemap . I grepped the response headers of all 79: zero hits. I grepped the repository for the string: zero hits.
There is exactly one CSP on the whole origin, and we did not write it:
curl -sI 'https://pub-trivia.app/_next/image?url=%2Fdemo-1.webp&w=1200&q=75' | grep -i security
Enter fullscreen mode
Exit fullscreen mode
content - security - policy : script - src 'none' ; frame - src 'none' ; sandbox ;
Enter fullscreen mode
Exit fullscreen mode
That is Next.js hardcoding a policy on its own image optimiser, on the sensible theory that a route which echoes bytes back at you should not be a script host.…