On Friday 27 August 2004 16:43, Lars Ellenberg wrote:
/ 2004-08-27 16:28:33 +0200
\ Raphael Leplae:
Hi,
I've setup the SuseFirewall2 on my web server, allowing access just via http and ssh, that was very easy with the GUI. Now if I need to block a specific domain, let say *.123.123.123, is there a simple way to do it in /etc/sysconfig/SuSEfirewall2 ? I was expecting something like: FW_REJECT_IP="*.123.123.123" but nothing like that in the examples provided in /usr/share/doc/packages/SuSEfirewall2/
I guess there is a simple way to do it. Thanks in advance.
either you mean 123.123.123.* ... then it is simply FW_REJECT_IP=123.123.123.0/24
Ooops, yes I meant 123.123.123.* I tested the FW_REJECT_IP key but doesn't seems having effect... My problem is that I want to block the following: 212.27.41.* These IPs are matching a "web robot" for a web search engine that doesn't recognise the robots.txt rules on my web server since they processes my cgi scripts despite my 'Disallow:/cgi-bin/' rule and cripple my server. Other "robots" behave ok. So the best is to stop them using the firewall. So I added in /etc/sysconfig/SuSEfirewall2 the line: FW_REJECT_IP=212.27.41.0/24 I restarted the suse firewall: /etc/init.d/SuSEfirewall2_final restart But the access is not blocked, the web server keeps being hammered by these 212.27.41.* :-( If the FW_REJECT_IP keyword is not recognised by SuseFirewall2, would an iptable line be recognised? It seems more complicated than I though... Thanks for the quick answer. Raphael -- ___________________________________________________________ Raphael Leplae, Ph.D. Research Scientist SCMBB - ULB Tel: +32 2 6505499 Blvd du Triomphe - CP 263 Fax: +32 2 6505425 1050 Brussels Belgium SCMBB Home Page http://www.scmbb.ulb.ac.be ACLAME - The Prokaryotic Mobilome http://aclame.ulb.ac.be ___________________________________________________________