From db614d36e6cddb97f2bf1b418656f9041674ef9f Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Sun, 15 Dec 2024 11:58:55 +0100 Subject: [PATCH] Block access to manifests in default nginx configurations --- deployment/docker/nginx.conf | 8 ++++++++ doc/admin/installation/manual_smallscale.rst | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/deployment/docker/nginx.conf b/deployment/docker/nginx.conf index 7f249b5507..6093014956 100644 --- a/deployment/docker/nginx.conf +++ b/deployment/docker/nginx.conf @@ -60,6 +60,14 @@ http { deny all; return 404; } + location /static/staticfiles.json { + deny all; + return 404; + } + location /static/CACHE/manifest.json { + deny all; + return 404; + } location /static/ { alias /pretix/src/pretix/static.dist/; access_log off; diff --git a/doc/admin/installation/manual_smallscale.rst b/doc/admin/installation/manual_smallscale.rst index 562a24e58b..8411540555 100644 --- a/doc/admin/installation/manual_smallscale.rst +++ b/doc/admin/installation/manual_smallscale.rst @@ -248,6 +248,14 @@ The following snippet is an example on how to configure a nginx proxy for pretix return 404; } + location /static/staticfiles.json { + deny all; + return 404; + } + location /static/CACHE/manifest.json { + deny all; + return 404; + } location /static/ { alias /var/pretix/venv/lib/python3.11/site-packages/pretix/static.dist/; access_log off;