Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <IfModule mod_rewrite.c>
- <IfModule mod_negotiation.c>
- Options -MultiViews -Indexes
- </IfModule>
- RewriteEngine On
- # Handle Authorization Header
- RewriteCond %{HTTP:Authorization} .
- RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
- # Redirect Trailing Slashes If Not A Folder...
- RewriteCond %{REQUEST_FILENAME} !-d
- RewriteCond %{REQUEST_URI} (.+)/$
- RewriteRule ^ %1 [L,R=301]
- # Handle Front Controller...
- RewriteCond %{REQUEST_FILENAME} !-d
- RewriteCond %{REQUEST_FILENAME} !-f
- RewriteRule ^ index.php [L]
- </IfModule>
- Options -Indexes
- <ifmodule mod_expires.c>
- <Filesmatch "\.(jpg|JPG|jpeg|png|PNG|gif|js|css|swf|ico|woff|mp3)$">
- ExpiresActive on
- ExpiresDefault "access plus 1 year"
- Header append Vary: Accept-Encoding
- </Filesmatch>
- </ifmodule>
- <IfModule mod_expires.c>
- ExpiresActive On
- ExpiresDefault "access plus 1 year"
- </IfModule>
- <IfModule mod_headers.c>
- <FilesMatch "\.(bmp|css|flv|gif|ico|jpg|jpeg|js|pdf|png|svg|swf|tif|tiff)$">
- Header set Last-Modified "Mon, 31 Aug 2009 00:00:00 GMT"
- </FilesMatch>
- </IfModule>
- #Gzip
- <ifmodule mod_deflate.c>
- AddOutputFilterByType DEFLATE text/text text/html text/plain text/xml text/css application/x- javascript application/javascript
- </ifmodule>
- #End Gzip
- <ifModule mod_gzip.c>
- mod_gzip_on Yes
- mod_gzip_dechunk Yes
- mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
- mod_gzip_item_include handler ^cgi-script$
- mod_gzip_item_include mime ^text/.*
- mod_gzip_item_include mime ^application/x-javascript.*
- mod_gzip_item_exclude mime ^image/.*
- mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
- </ifModule>
- ## EXPIRES CACHING ##
- <IfModule mod_expires.c>
- ExpiresActive On
- ExpiresByType image/jpg "access 1 year"
- ExpiresByType image/jpeg "access 1 year"
- ExpiresByType image/gif "access 1 year"
- ExpiresByType image/png "access 1 year"
- ExpiresByType text/css "access 1 month"
- ExpiresByType text/html "access 1 month"
- ExpiresByType application/pdf "access 1 month"
- ExpiresByType text/x-javascript "access 1 month"
- ExpiresByType application/x-shockwave-flash "access 1 month"
- ExpiresByType image/x-icon "access 1 year"
- ExpiresDefault "access 1 month"
- </IfModule>
- ## EXPIRES CACHING ##
- <IfModule mod_rewrite.c>
- RewriteCond %{HTTP_USER_AGENT} ^w3af.sourceforge.net [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} dirbuster [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} nikto [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} SF [OR]
- RewriteCond %{HTTP_USER_AGENT} sqlmap [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} fimap [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} nessus [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} whatweb [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} Openvas [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} jbrofuzz [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} libwhisker [NC,OR]
- RewriteCond %{HTTP_USER_AGENT} webshag [NC,OR]
- RewriteCond %{HTTP:Acunetix-Product} ^WVS
- RewriteRule ^.* http://127.0.0.1/ [R=301,L]
- </IfModule>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement