From d18c76fc8895f8b25d0aa0b41d506aee710d8b5b Mon Sep 17 00:00:00 2001 From: Mitesh Shah Date: Tue, 10 Sep 2013 17:37:14 +0530 Subject: [PATCH] Deny Backup Extensions & Log Files --- etc/nginx/common/locations.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/nginx/common/locations.conf b/etc/nginx/common/locations.conf index 441b4ea8..9c89df7b 100644 --- a/etc/nginx/common/locations.conf +++ b/etc/nginx/common/locations.conf @@ -76,8 +76,8 @@ location ~ /\. { log_not_found off; } -# Deny To .log Extension -location ~* ^.+\.log$ { +# Deny Backup Extensions & Log Files +location ~* ^.+\.(bak|log|orig|original|php~|php_bak|save|swo|swp)$ { deny all; access_log off; log_not_found off;