How to block an abusive bot such as ShopWiki using iptables firewall

No GoodNeed ImprovementOKGoodExcellent (1 votes, average: 5 out of 5)
Loading ... Loading ...

You can use the following shell script to block an abusive bot, such as ShopWiki,

#!/bin/sh
#/sbin/route add -host $1 reject
iptables -I INPUT -s $1 -j DROP
iptables -L -n

save this script as block_ip.sh

to block bad IP, execute the shell script:

block_ip.sh 64.92.164.138

This will block the bad guy from 64.92.164.138.

Popularity: 2%

1 Comment »

  1. saran said,

    August 6, 2007 @ 2:48 am

    Hi Everybody,

    i wanna block particular websites for specified ip’s only using iptables..

    Then how can i block it.. Please help me…..

    If any way to block that one(execpt iptables)..
    Please send to me ..

    My mail id is saravanaprakasht@yahoo.com

RSS feed for comments on this post · TrackBack URI

Leave a Comment

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word