diff --git a/templates/nginx-virthost.j2 b/templates/nginx-virthost.j2 index b46e441..95a0c5b 100644 --- a/templates/nginx-virthost.j2 +++ b/templates/nginx-virthost.j2 @@ -39,7 +39,7 @@ server { return 404; } {% elif nginx_block_dangerous_dotfiles %} - location ~ /\.ht.* { + location ~ /\.(?ht).* { deny all; access_log off; log_not_found off; @@ -257,7 +257,7 @@ server { return 404; } {% elif nginx_block_dangerous_dotfiles %} - location ~ /\.ht.* { + location ~ /\.(?ht).* { deny all; access_log off; log_not_found off;