Advertisement
Guest User

protect htaccess

a guest
Jan 25th, 2014
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. <files wp-config.php>
  2. order allow,deny
  3. deny from all
  4. </files>
  5.  
  6. <Files .htaccess>
  7. order allow,deny
  8. deny from all
  9. </Files>
  10.  
  11.  
  12. # prevent directory browsing
  13. Options -Indexes
  14. Order Allow,Deny
  15. Deny from all
  16.  
  17.  
  18. # Block the include-only files.
  19. <IfModule mod_rewrite.c>
  20. RewriteEngine On
  21. RewriteBase /
  22. RewriteRule ^wp-admin/includes/ - [F,L]
  23. RewriteRule !^wp-includes/ - [S=3]
  24. RewriteRule ^wp-includes/[^/]+\.php$ - [F,L]
  25. RewriteRule ^wp-includes/js/tinymce/langs/.+\.php - [F,L]
  26. RewriteRule ^wp-includes/theme-compat/ - [F,L]
  27. </IfModule>
  28.  
  29.  
  30. # BEGIN W3TC Browser Cache
  31. gzip on;
  32. gzip_types text/css text/x-component application/x-javascript application/javascript text/javascript text/x-js text/richtext image/svg+xml text/plain text/xsd text/xsl text/xml image/x-icon;
  33. # END W3TC Browser Cache
  34.  
  35. #BEGIN WP SEO: XML Sitemaps
  36. rewrite ^/sitemap_index\.xml$ /index.php?sitemap=1 last;
  37. rewrite ^/([^/]+?)-sitemap([0-9]+)?\.xml$ /index.php?sitemap=$1&sitemap_n=$2 last;
  38. # END WP SEO: XML Sitemaps
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement