Micronovae
Home Products Downloads Purchase Support Company
Overview Documentation Download Purchase FAQ
 
IIS Mod-Rewrite

Example: Robot blocking

Scenario:

In this example we want to block all requests made by an annoying robot. Usually the robots are identified by their name contained in the "User-agent" HTTP header.

Configuration:

#Turn IIS Mod-Rewrite engine on
RewriteEngine On

#Check if "User-agent" HTTP header contains "AnnoyBot"...
RewriteCond %{HTTP_USER_AGENT} AnnoyBot [NC]
#...and if so, send a "Forbidden" HTTP header for any request.
RewriteRule .* - [F]