code_junkie

How can I detect and survive being “Slashdotted”?

Nov 11th, 2011
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. <IfModule mod_rewrite.c>
  2. RewriteEngine On
  3. RewriteBase /
  4.  
  5. RewriteCond %{HTTP_USER_AGENT} !^Googlebot
  6. RewriteCond %{HTTP_USER_AGENT} !^CoralWebPrx
  7. RewriteCond %{QUERY_STRING} !(^|&)coral-no-serve$
  8. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?digg.com [OR]
  9. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?slashdot.org [OR]
  10. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?slashdot.com [OR]
  11. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?fark.com [OR]
  12. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?somethingawful.com [OR]
  13. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?kuro5hin.org [OR]
  14. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?engadget.com [OR]
  15. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?boingboing.net [OR]
  16. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?del.icio.us [OR]
  17. RewriteCond %{HTTP_REFERER} ^http://([^/]+.)?delicious.com
  18. RewriteRule ^(.*)?$ http://example.com.nyud.net/$1 [R,L]
  19. </IfModule>
  20.  
  21. RewriteEngine on
  22. RewriteCond %{HTTP_REFERER} slashdot.org [NC]
  23. RewriteRule .* - [F]
Add Comment
Please, Sign In to add comment