Skip to content

Instantly share code, notes, and snippets.

Created April 28, 2015 23:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/9c89e2841e00177eb92a to your computer and use it in GitHub Desktop.
Save anonymous/9c89e2841e00177eb92a to your computer and use it in GitHub Desktop.
Options +FollowSymlinks
Options -Indexes
<FilesMatch "\.(tpl|ini|log)">
Order deny,allow
Deny from all
</FilesMatch>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_REFERER} simple\-share\-buttons\.com [NC,OR]
RewriteCond %{HTTP_REFERER} sharebutton\.net [NC,OR]
RewriteCond %{HTTP_REFERER} pornhub\-forum\.ga [NC,OR]
RewriteCond %{HTTP_REFERER} buttons\-for\-your\-website\.com [NC,OR]
RewriteCond %{HTTP_REFERER} torture\.ml [NC,OR]
RewriteCond %{HTTP_REFERER} best\-seo\-offer\.com [NC,OR]
RewriteCond %{HTTP_REFERER} free\-share\-buttons\.com [NC,OR]
RewriteCond %{HTTP_REFERER} youporn\-forum\.ga [NC,OR]
RewriteCond %{HTTP_REFERER} generalporn\.org [NC,OR]
RewriteCond %{HTTP_REFERER} rapidgator\-porn\.ga [NC,OR]
RewriteCond %{HTTP_REFERER} digadz\.com [NC,OR]
RewriteCond %{HTTP_REFERER} depositfiles\-porn\.ga [NC,OR]
RewriteCond %{HTTP_REFERER} buy\-cheap\-online\.info [NC]
RewriteRule .* - [F]
RewriteCond %{HTTP_HOST} ^blog\.mysiteexample\.com [NC]
RewriteRule ^(.*) - [L]
RewriteCond %{HTTP_HOST} !^www\.mysiteexample\.com [NC]
RewriteRule ^(.*) http://www.mysiteexample.com/$1 [L,R=301]
</IfModule>
RewriteBase /
#RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L]
#RewriteRule ^googlebase.xml$ index.php?route=feed/google_base [L]
RewriteRule ^download/(.*) /index.php?route=error/not_found [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*\.(ico|gif|jpg|jpeg|png|js|css)
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]
# BEGIN Rabbit Rabbit
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript
# Remove Browser Bugs
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
Header append Vary User-Agent
# Leverage Browser Caching
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access plus 1 week"
ExpiresByType image/jpeg "access plus 1 week"
ExpiresByType image/gif "access plus 1 week"
ExpiresByType image/png "access plus 1 week"
ExpiresByType text/css "access plus 1 week"
ExpiresByType application/pdf "access plus 1 week"
ExpiresByType text/x-javascript "access plus 1 week"
ExpiresByType application/x-shockwave-flash "access plus 1 week"
ExpiresByType image/x-icon "access plus 1 week"
ExpiresDefault "access plus 1 week"
</IfModule>
# END Rabbit Rabbit
Header set X-Frame-Options DENY
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment