SageVenture
SageVenture

Reputation: 11

How do I block IPs using htaccess

How can I stop these IP addresses from hitting my site (185...* and 93.127..).
I have tried these in .htaccess:

Order Allow,Deny

Deny from 185.162.0.0/15

Deny from 185.164.0.0/14

Deny from 185.168.0.0/13

Deny from 185.176.0.0/12

Deny from 185.192.0.0/11

Deny from 93.127.0.0/16

Allow from all

and bots from http://tab-studio.com/en/blocking-robots-on-your-page/ but I continue to be hit.

Upvotes: 0

Views: 1256

Answers (1)

Anderson B Silva
Anderson B Silva

Reputation: 1

Good: Edit (or create) the .htaccess file in the root of your server and put the following code:

order allow, deny
deny from 210.140.98.160
deny from 69.197.132.70
deny from 74.14.13.236
allow from all

Upvotes: 0

Related Questions