From 613c59efdd69bd596576cbc420527ab75d635ed1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C6=ACHE=20=D0=AFAW=20=E2=98=A3?= Date: Sat, 24 Feb 2018 13:58:27 +0100 Subject: [PATCH] Update default --- static/vhost/default | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/static/vhost/default b/static/vhost/default index f5a7976..27f6656 100644 --- a/static/vhost/default +++ b/static/vhost/default @@ -3,6 +3,10 @@ server { root /hostdata/default/public_html; index index.html; server_name localhost; + + # LIMIT CONNECTION FOR IP / IPs WILL BE AUTO BANNED IF YOU HAVE INSTALL IPTABLES/FAIL2BAN + limit_conn max 800; + limit_req zone=one burst=300 nodelay; location / { SecRulesEnabled; @@ -14,11 +18,13 @@ server { CheckRule "$EVADE >= 4" BLOCK; CheckRule "$XSS >= 8" BLOCK; - access_log /hostdata/default/logs/access.log main; - error_log /hostdata/default/logs/error.log; - try_files $uri $uri/ =404; } + + access_log /hostdata/default/logs/access.log main; + # ERROR.log path shouldn't be changed! or change this https://github.com/theraw/The-World-Is-Yours/blob/master/iptables/jail.local#L110 + error_log /nginx/logs/error.log; + location /denied/ { return 444; }