PDA

Zobacz pełną wersję : .htaccess w załączeniu



sylkasylka
11-07-2007, 14:07
w załączeniu treść do umieszczenia w pliku .htaccess zawierający dyrektywy dot. bezpieczeństwa związanego z atakami

bardziej biegłych proszę o weryfikację czy jest ok
i dopisywanie adresów ip
__________________________________________________ __________

########## Begin - Rewrite rules to block out some common exploits
#
# Block out any script trying to set a mosConfig value through the URL
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]
# Block out any script trying to base64_encode crap to send via URL
RewriteCond %{QUERY_STRING} base64_encode.*\(.*\) [OR]
# Block out any script that includes a <script> tag in URL
RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
# Block out any script trying to set a PHP GLOBALS variable via URL
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
# Block out any script trying to modify a _REQUEST variable via URL
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
# Send all blocked request to homepage with 403 Forbidden error!
RewriteRule ^(.*)$ index.php [F,L]
#
########## End - Rewrite rules to block out some common exploits

<Files 403.shtml>
order allow,deny
allow from all
</Files>

# zone h
deny from .zone-h.org
deny from .zone-h.com
deny from 213.219.122

# cyber-warrior.org
deny from .cyber-warrior.org
deny from .cyber-security.org
deny from 80.237.211.8
Deny from 201.244.38
Deny from 83.130.9.178
Deny from 212.138.113.25
Deny from 212.138.113.23
Deny from cache4-1.ruh.isu.net.sa
Deny from 212.138.113.24
Deny from cache3-2.ruh.isu.net.sa
Deny from cache11-4.ruh.isu.net.sa
Deny from 202.8.85.11
Deny from 222.124.11.98
Deny from 62.148.177.26
Deny from 85.88.1.99
Deny from 85.97.67.181
Deny from 62.139.173.167
Deny from 212.138.113.23
Deny from 62.139.173.167
Deny from 82.129.189.97
Deny from 222.124.11.98
Deny from cache5-1.ruh.isu.net.sa
Deny from 82.145.205.194
Deny from pool-71-247-228-228.nycmny.east.verizon.net
Deny from 71.247.228.228
Deny from 202.65.236.122
Deny from 81.215.171.81
Deny from 85.101.138.179
Deny from 196.1.176.50
Deny from 136.red-83-45-120.dynamicip.rima-tde.net
Deny from 213.63.133.117
Deny from 63.94.224.93
Deny from h19.plesklogin.net
Deny from s2.server4user.de
Deny from seki.lunarpages.com
Deny from 82.165.151.41
Deny from fin01.rackglobal.com
Deny from s21.domenomania.pl
Deny from u15181562.onlinehome-server.com
Deny from dirgencom.drac.net
Deny from esc79.midphase.com

#.mischel.cz
Deny from 201.244.38

#t3ch.addyour.net
deny from .t3ch.addyour.net
deny from 62.149.0.117

#milw0rm.org
deny from .milworm.org
deny from 208.66.195.0/28

#blokowanie dostepu z adresow IP
deny from 85.102.201.9
deny from 85.103.232.27
deny from 62.150.154.23
deny from 217.16.29.51
deny from 200.189.60
deny from 202.95.135
deny from 82.207.99