[security.conf]
#include the desired site's conf file
RewriteEngine ON
#RewriteLog rwlog.log
#RewriteLogLevel 5 
## BLACKLIST IPS ##
RewriteMap ipslist txt:/etc/security/blacklistip
RewriteCond %{REMOTE_ADDR} ^(.*)$
RewriteCond ${ipslist:%1|white} ^black$ [NC]
RewriteRule (.*) - [F]
## TRAP REQUESTS ##
RewriteMap reqlist txt:/etc/security/bad_requests
RewriteCond %{REQUEST_URI} ^/*(\S+)/*$ [NC]
RewriteCond ${reqlist:%1|white} ^black$ [NC]
RewriteRule (.*) "/trap.php" [L]
## RFI Prevention ##
RewriteCond %{THE_REQUEST} GET\ ((http)|(ftp))(://|s://)+.* 
RewriteRule (.*) "/trap.php" [L]

