From 19851ec1fce3fabec3c6f951c3fb7d5814d24691 Mon Sep 17 00:00:00 2001 From: Daniel Schaefer Date: Wed, 26 Jun 2019 20:45:55 +0200 Subject: [PATCH] nixos/zoneminder: Fix nginx config check NixOS wouldn't build because the nginx config checker fails. Location without a trailing slash "could allow an attacker to read file stored outside the target folder.", source: https://github.com/yandex/gixy/blob/master/docs/en/plugins/aliastraversal.md Shouldn't change the behaviour according to https://serverfault.com/questions/607615/using-trailing-slashes-in-nginx-configuration/607731#607731 --- nixos/modules/services/misc/zoneminder.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/modules/services/misc/zoneminder.nix b/nixos/modules/services/misc/zoneminder.nix index 9c555e8031c4..cd65e461f471 100644 --- a/nixos/modules/services/misc/zoneminder.nix +++ b/nixos/modules/services/misc/zoneminder.nix @@ -256,7 +256,7 @@ in { fastcgi_pass ${fcgi.socketType}:${fcgi.socketAddress}; } - location /cache { + location /cache/ { alias /var/cache/${dirName}; }