From 0ace2e232e5f3a536dde28181a4454ffabd6427a Mon Sep 17 00:00:00 2001 From: Basil Bruhn Date: Tue, 11 Nov 2025 11:50:02 +0100 Subject: [PATCH] java script errors Signed-off-by: Basil Bruhn --- conf.d/rfmwtools-test.conf | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/conf.d/rfmwtools-test.conf b/conf.d/rfmwtools-test.conf index 6a59873..d1a9f70 100644 --- a/conf.d/rfmwtools-test.conf +++ b/conf.d/rfmwtools-test.conf @@ -19,12 +19,21 @@ server { access_log /var/log/nginx/rfmwtools-test.access.log; error_log /var/log/nginx/rfmwtools-test.error.log; + # CSP-only framing + add_header Content-Security-Policy "frame-ancestors https://*.psi.ch" always; + add_header X-Frame-Options "" always; + + location ~* \.(js|css|html|gif|png|jpg|ico)$ { + autoindex off; + try_files $uri =404; + } + location / { autoindex on; autoindex_exact_size off; autoindex_localtime on; - try_files $uri $uri/ =404; + try_files $uri/ =404; } }