How To Block Spammers/Hackers With Apache2's mod_spamhaus (Debian Etch)
How To Block Spammers/Hackers With Apache2's mod_spamhaus (Debian Etch)mod_spamhaus is an Apache module that uses DNSBL in order to block spam relay via web forms, preventing URL injection, block http DDoS attacks from bots and generally protecting your web service denying access to a known bad IP address.
1. InstallationIn order to compile mod_spamhaus, you must have apxs2 (APache eXtenSion tool) tool installed. The follow command will install it: apt-get install apache2-prefork-dev Now we need to download the source package present at http://sourceforge.net/projects/mod-spamhaus/ or download it using wget application and this direct link to the repository: wget http://kent.dl.sourceforge.net/sourceforge/mod-spamhaus/mod_spamhaus05.tar.gz Next open archive, compile and install module with those commands: tar zxvf mod_spamhaus05.tar.gz You must add LoadModule directive to the main config file of you're web server to load mod_spamhaus module. vi /etc/apache2/httpd.conf
2. ConfigurationBefore we are able to write our configuration, we should known what directives are supported by mod_spamhaus: MS_Methods - If the httpd's method used by the visitor match, module verify user's ip addressMS_WhiteList - A simple whitelist file where you can put ip address to bypass MS_DNS - DNSBL to use. Usefull if you want make a local rbldnsd instance MS_CacheSize - Number of cached addresses Now we open config file of our web server in order to write a basic configuration: vi /etc/apache2/apache2.conf
Next we create an empty whitelist file: touch /etc/spamhaus.wl Finally we restart Apache2: /etc/init.d/apache2 restart That's all!
3. Links
|
www.seamlessenterprise.com
One number. One voicemail. Seize the lead. Sprint Mobile Integration.
www.seamlessenterprise.com
One Number. One Voicemail.
Make it easier for clients to reach you. Turn your desk phone and mobile phone into one with Sprint Mobile Integration.
www.seamlessenterprise.com
One number. One voicemail. Sprint Mobile Integration.
www.seamlessenterprise.com
AT&T Synaptic Compute as a Service. Boost your power on demand.
Trial: IBM Cognos Express Reporting, Analysis & Planning







Recent comments
6 hours 30 min ago
8 hours 31 min ago
11 hours 42 min ago
14 hours 1 min ago
15 hours 11 min ago
16 hours 30 min ago
20 hours 33 min ago
1 day 7 min ago
1 day 19 min ago
1 day 15 hours ago