From 53c0e9f9b8bcfb8d3e668337924f4b8509d46203 Mon Sep 17 00:00:00 2001 From: Exile Date: Thu, 25 Sep 2014 16:33:05 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9A=D0=BE=D0=BD=D1=84=D0=B8=D0=B3=D0=B8,=20?= =?UTF-8?q?=D1=80=D0=B5=D0=B2=D1=80=D0=B0=D0=B9=D1=82=D1=8B,=20=D0=BB?= =?UTF-8?q?=D0=B8=D1=88=D0=BD=D1=8F=D1=8F=20=D0=BF=D0=B0=D0=BF=D0=BA=D0=B0?= =?UTF-8?q?.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 4 ---- install/php-fpm+nginx/nginx.conf | 7 +++++-- upload/.htaccess | 5 ++++- upload/internal_data/cache/filecache/.htaccess | 2 -- 4 files changed, 9 insertions(+), 9 deletions(-) delete mode 100644 upload/internal_data/cache/filecache/.htaccess diff --git a/README.md b/README.md index 876eae050..831135f27 100644 --- a/README.md +++ b/README.md @@ -31,14 +31,10 @@ TorrentPier II - движок торрент-трекера, написанны - internal_data/ajax_html - internal_data/atom - internal_data/cache -- internal_data/cache/filecache - internal_data/captcha - internal_data/log - internal_data/sitemap - internal_data/triggers -- styles/images -- styles/images/ranks -- styles/images/smiles ## Необходимые настройки php diff --git a/install/php-fpm+nginx/nginx.conf b/install/php-fpm+nginx/nginx.conf index e32641d2a..b96c28a6e 100644 --- a/install/php-fpm+nginx/nginx.conf +++ b/install/php-fpm+nginx/nginx.conf @@ -125,13 +125,16 @@ http { location ~ \/admin|backup\/ { deny all; - # allow YOUR_IP; + #allow YOUR_IP; } # Deny folder (Sec. lvl1) - location ~ \/(cache|log|attach_mod|config|includes|language|triggers)\/ { + location ~ \/(internal_data|library)\/ { deny all; } + # sitemap rewrite + rewrite ^/sitemap.xml$ /internal_data/sitemap/sitemap.xml; + # deny access to .htaccess files, if Apache's document root # concurs with nginx's one # deny sql,tpl,db,inc,log diff --git a/upload/.htaccess b/upload/.htaccess index dd1ef258a..90e71cb17 100644 --- a/upload/.htaccess +++ b/upload/.htaccess @@ -6,4 +6,7 @@ Options All -Indexes deny from all - \ No newline at end of file + + +RewriteEngine On +RewriteRule ^sitemap.xml$ internal_data/sitemap/sitemap.xml [L] \ No newline at end of file diff --git a/upload/internal_data/cache/filecache/.htaccess b/upload/internal_data/cache/filecache/.htaccess deleted file mode 100644 index baa56e5a3..000000000 --- a/upload/internal_data/cache/filecache/.htaccess +++ /dev/null @@ -1,2 +0,0 @@ -order allow,deny -deny from all \ No newline at end of file