Page 1 of 1
How block some IP´s
Posted: Thu Sep 02, 2010 7:18 am
by m0rpheu5
Hello guys, i need to block the IP´s 66.151.129.* how can i do that without add one per one.
Thanks
Re: How block some IP´s
Posted: Thu Sep 02, 2010 11:51 am
by magicspam
At this time bulk IP blocking (or exemption) support is not supported. The core reason is that there are many ways to specify ranges (be it CIDR notation, netmasks, dash dot ranges...etc) and is very very easy for one to make a wrong entry that could cause damage / harm to production services.
This stated... there are several 'IP' address generator scripts available out there. You could use one of these scripts to generate a file with the individual IP's. From there, simply append the contents of said file to the MagicSpam control file which is handily stored in plain text for these exact purposes:
/etc/magic-spam/blocked_ips