1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Blocking nasty bots!

Discussion in 'Apache' started by Muhammad Haris, Mar 7, 2007.

  1. #1
    RewriteEngine on
    RewriteBase /
    RewriteCond %{HTTP_USER_AGENT} ^EmailSiphon [OR]
    RewriteCond %{HTTP_USER_AGENT} ^EmailWolf [OR]
    RewriteCond %{HTTP_USER_AGENT} ^ExtractorPro [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Mozilla.*NEWT [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Crescent [OR]
    RewriteCond %{HTTP_USER_AGENT} ^CherryPicker [OR]
    RewriteCond %{HTTP_USER_AGENT} ^[Ww]eb[Bb]andit [OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebEMailExtrac.* [OR]
    RewriteCond %{HTTP_USER_AGENT} ^NICErsPRO [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Teleport [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Zeus.*Webster [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Microsoft.URL [OR]
    RewriteCond %{HTTP_USER_AGENT} ^Wget [OR]
    RewriteCond %{HTTP_USER_AGENT} ^LinkWalker [OR]
    RewriteCond %{HTTP_USER_AGENT} ^sitecheck.internetseer.com [OR]
    RewriteCond %{HTTP_USER_AGENT} ^ia_archiver [OR]
    RewriteCond %{HTTP_USER_AGENT} ^DIIbot [OR]
    RewriteCond %{HTTP_USER_AGENT} ^psbot [OR]
    RewriteCond %{HTTP_USER_AGENT} ^EmailCollector
    RewriteRule ^.* - [F]
    RewriteRule !^http://[^/.]\.your-site.com.* - [F] 
    Code (markup):
    This is the code which I will use for blocking nasty bots accessing my site but I want it so they get 404 error if they go to somedomain.com or somedomain2.com and not the domains which I've not included.

    Can someone please add the above feature to the code?
     
    Muhammad Haris, Mar 7, 2007 IP
    hsaleem likes this.
  2. Muhammad Haris

    Muhammad Haris Peon

    Messages:
    576
    Likes Received:
    34
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Can someone help me?
     
    Muhammad Haris, Mar 7, 2007 IP