<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://docs.sandbox.joomla.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Ahmad</id>
	<title>Joomla! Documentation - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://docs.sandbox.joomla.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Ahmad"/>
	<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/Special:Contributions/Ahmad"/>
	<updated>2026-08-28T00:54:36Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.0</generator>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=Htaccess_examples_(security)&amp;diff=64362</id>
		<title>Htaccess examples (security)</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=Htaccess_examples_(security)&amp;diff=64362"/>
		<updated>2012-01-22T11:03:15Z</updated>

		<summary type="html">&lt;p&gt;Ahmad: /* Suggested Master htaccess file */ Updated the file version from Nicholas Dionysopoulos SVN&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&#039;&#039;Credit for part of this .htaccess file goes to Ronald van den Heetkamp&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
For this to work you need RewriteEngine set to On, and will likely also need Options +FollowSymLinks too:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;apache&amp;quot;&amp;gt;&lt;br /&gt;
 # mod_rewrite in use&lt;br /&gt;
 RewriteEngine On&lt;br /&gt;
 Options +FollowSymLinks&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Block bad user agents ==&lt;br /&gt;
&amp;lt;source lang=&amp;quot;apache&amp;quot;&amp;gt;&lt;br /&gt;
 ########## Block bad user agents&lt;br /&gt;
 ## The following list may include bots that no longer exist or are not a problem&lt;br /&gt;
 ## for your site. The list will always be incomplete and it is therefore wise to&lt;br /&gt;
 ## follow discussions on one of the many &amp;quot;security&amp;quot; mailing lists or on a forum&lt;br /&gt;
 ## such as http://www.webmasterworld.com/search_engine_spiders/&lt;br /&gt;
 ## It is also unwise to rely on this list as your ONLY security mechanism.&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^BlackWidow [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Bot\ mailto:craftbot@yahoo.com [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^ChinaClaw [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Custo [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^DISCo [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Download\ Demon [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^eCatch [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^EirGrabber [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^EmailSiphon [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^EmailWolf [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Express\ WebPictures [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^ExtractorPro [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^EyeNetIE [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^FlashGet [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^GetRight [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^GetWeb! [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Go!Zilla [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Go-Ahead-Got-It [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^GrabNet [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Grafula [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^HMView [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} HTTrack [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Image\ Stripper [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Image\ Sucker [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} Indy\ Library [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^InterGET [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Internet\ Ninja [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^JetCar [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^JOC\ Web\ Spider [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^larbin [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^LeechFTP [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Mass\ Downloader [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^MIDown\ tool [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Mister\ PiX [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Navroad [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^NearSite [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^NetAnts [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^NetSpider [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Net\ Vampire [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^NetZIP [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Octopus [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Offline\ Explorer [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Offline\ Navigator [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^PageGrabber [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Papa\ Foto [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^pavuk [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^pcBrowser [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^RealDownload [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^ReGet [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^SiteSnagger [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^SmartDownload [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^SuperBot [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^SuperHTTP [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Surfbot [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^tAkeOut [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Teleport\ Pro [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^VoidEYE [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Web\ Image\ Collector [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Web\ Sucker [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebAuto [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebCopier [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebFetch [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebGo\ IS [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebLeacher [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebReaper [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebSauger [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Website\ eXtractor [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Website\ Quester [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebStripper [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebWhacker [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WebZIP [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Widow [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^WWWOFFLE [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Xaldon\ WebSpider [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^Zeus&lt;br /&gt;
 ## Note: The final RewriteCond must NOT use the [OR] flag.&lt;br /&gt;
&lt;br /&gt;
 ## Return 403 Forbidden error.&lt;br /&gt;
 RewriteRule .* - [F]&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other useful settings ==&lt;br /&gt;
&amp;lt;source lang=&amp;quot;apache&amp;quot;&amp;gt;&lt;br /&gt;
 ServerSignature Off&lt;br /&gt;
 RewriteCond %{REQUEST_METHOD} ^(HEAD|TRACE|DELETE|TRACK) [NC,OR]&lt;br /&gt;
 RewriteCond %{THE_REQUEST} (\\r|\\n|%0A|%0D) [NC,OR]&lt;br /&gt;
&lt;br /&gt;
 RewriteCond %{HTTP_REFERER} (&amp;lt;|&amp;gt;|’|%0A|%0D|%27|%3C|%3E|%00) [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_COOKIE} (&amp;lt;|&amp;gt;|’|%0A|%0D|%27|%3C|%3E|%00) [NC,OR]&lt;br /&gt;
 RewriteCond %{REQUEST_URI} ^/(,|;|:|&amp;lt;|&amp;gt;|”&amp;gt;|”&amp;lt;|/|\\\.\.\\).{0,9999} [NC,OR]&lt;br /&gt;
&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^$ [OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} ^(java|curl|wget) [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} (winhttp|HTTrack|clshttp|archiver|loader|email|harvest|extract|grab|miner) [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} (libwww-perl|curl|wget|python|nikto|scan) [NC,OR]&lt;br /&gt;
 RewriteCond %{HTTP_USER_AGENT} (&amp;lt;|&amp;gt;|’|%0A|%0D|%27|%3C|%3E|%00) [NC,OR]&lt;br /&gt;
 &lt;br /&gt;
 #Block mySQL injects&lt;br /&gt;
 RewriteCond %{QUERY_STRING} (;|&amp;lt;|&amp;gt;|’|”|\)|%0A|%0D|%22|%27|%3C|%3E|%00).*(/\*|union|select|insert|cast|set|declare|drop|update|md5|benchmark) [NC,OR]&lt;br /&gt;
&lt;br /&gt;
 RewriteCond %{QUERY_STRING} \.\./\.\. [OR]&lt;br /&gt;
&lt;br /&gt;
 RewriteCond %{QUERY_STRING} (localhost|loopback|127\.0\.0\.1) [NC,OR]&lt;br /&gt;
 RewriteCond %{QUERY_STRING} \.[a-z0-9] [NC,OR]&lt;br /&gt;
 RewriteCond %{QUERY_STRING} (&amp;lt;|&amp;gt;|’|%0A|%0D|%27|%3C|%3E|%00) [NC]&lt;br /&gt;
 # Note: The final RewriteCond must NOT use the [OR] flag.&lt;br /&gt;
&lt;br /&gt;
 # Return 403 Forbidden error.&lt;br /&gt;
 RewriteRule .* index.php [F]&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Suggested Master htaccess file ==&lt;br /&gt;
&lt;br /&gt;
This can be discussed in [http://forum.joomla.org/viewtopic.php?f=432&amp;amp;t=549841 this forum topic]&lt;br /&gt;
&lt;br /&gt;
The file can be found on svn over [https://akeeba.assembla.com/code/master-htaccess/git/nodes/htaccess.txt]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Warning: note the hashed areas. Incorrect settings on some servers may cause 500 page errors&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=&amp;quot;apache&amp;quot;&amp;gt;&lt;br /&gt;
###############################################################################&lt;br /&gt;
## The Master .htaccess&lt;br /&gt;
##&lt;br /&gt;
## Version 3.3 - WORK IN PROGRESS&lt;br /&gt;
##&lt;br /&gt;
## ----------&lt;br /&gt;
## This file is designed to be the template .htaccess file to put on your new&lt;br /&gt;
## sites, increasing your site&#039;s security and performance. It is not meant to&lt;br /&gt;
## be just dropped in your site, though. You should go through all of its&lt;br /&gt;
## sections and modify it to match your site. Most notably, all instances of&lt;br /&gt;
## example.com and example\.com should be replaced with your real domain name.&lt;br /&gt;
##&lt;br /&gt;
## Some sections are too picky and may cause problems with legitimate requests.&lt;br /&gt;
## You are ultimately responsible for disabling them or writing exception rules&lt;br /&gt;
## for your requests. Most notably, the advanced server protection section will&lt;br /&gt;
## cause issues with several minifiers, eXtplorer, VirtueMart and other exten-&lt;br /&gt;
## sions which use non-standard scripts as their entry points. You must add&lt;br /&gt;
## exceptions for them manually.&lt;br /&gt;
##&lt;br /&gt;
## Some sections - depending on your server configuration - may cause your site&lt;br /&gt;
## to throw 500 Internal Server Error. The only way to figure out which one is&lt;br /&gt;
## causing it is trial and error.&lt;br /&gt;
##&lt;br /&gt;
## Big thank you&#039;s to Brian Teeman, Ken Crowder, Radek Suski and Fotis&lt;br /&gt;
## Evangelou for sharing their .htaccess rules with the world and inspiring&lt;br /&gt;
## the creation of this file. Special thanks to Jon Brown for sharing his&lt;br /&gt;
## research and helping me improve this file.&lt;br /&gt;
##&lt;br /&gt;
## Additional thank-yous to John for his remarks and g1smd for taking the&lt;br /&gt;
## time to optimize the speed of the file.&lt;br /&gt;
##&lt;br /&gt;
## It is usually prudent to remove the comments from the file when using it&lt;br /&gt;
## on a live host to minimize the parsing time.&lt;br /&gt;
##&lt;br /&gt;
## ----------------------------------------------------------------------&lt;br /&gt;
## Do you want to customize this .htaccess file with a few clicks?&lt;br /&gt;
## Admin Tools Professional by AkeebaBackup.com does this and much more.&lt;br /&gt;
##&lt;br /&gt;
## Learn more: http://www.akeebabackup.com/software/admin-tools.html&lt;br /&gt;
## ----------------------------------------------------------------------&lt;br /&gt;
##&lt;br /&gt;
## Have fun, stay safe.&lt;br /&gt;
##&lt;br /&gt;
## Nicholas K. Dionysopoulos&lt;br /&gt;
## Lead Developer, AkeebaBackup.com&lt;br /&gt;
##&lt;br /&gt;
## CHANGELOG:&lt;br /&gt;
## Version 3.3 (PENDING RELEASE)&lt;br /&gt;
## - Version 3.2 wasn&#039;t tested and killed some sites&lt;br /&gt;
## Version 3.2 (April 8th, 2011)&lt;br /&gt;
## - Some slight improvements with negligible (if any) performance impact&lt;br /&gt;
## Version 3.1 (April 5th, 2011)&lt;br /&gt;
## - Expiration time of static resources adjusted to 1 month instead of 1 year&lt;br /&gt;
## - GET variables not passed along in the index.php to site root redirection&lt;br /&gt;
## - Fixed typos&lt;br /&gt;
## - Alternative for HTTP to HTTPS redirection&lt;br /&gt;
## - Common exploits protection: Minor changes in comments, combined base64_encode/base64_decode rule&lt;br /&gt;
## - Bug in query string protection rule&lt;br /&gt;
## - Back-end &amp;amp; front-end protection optimization&lt;br /&gt;
## - Fixed the UNION SELECT SQLi rule to actually work against real attacks&lt;br /&gt;
## - Added comments to Joomla! core SEF section&lt;br /&gt;
## Version 3.0 (March 28th, 2011)&lt;br /&gt;
## - Massive rewrite&lt;br /&gt;
## Version 2.3 (November 18th, 2010)&lt;br /&gt;
## - Added .ico to the pass-through rules, for favicons to load&lt;br /&gt;
## Version 2.2 (October 25th, 2010)&lt;br /&gt;
## - Bug in the tmpl=component rule&lt;br /&gt;
## Version 2.1 (October 19th, 2010)&lt;br /&gt;
## - index.php to root redirection would kill some AJAX requests&lt;br /&gt;
## - Referer filtering was screwed up&lt;br /&gt;
## - Simplified and more thorough PHP Easter Egg code (thanks Jon!)&lt;br /&gt;
## - The tp/template/tmpl filter was not thorough and killed some components&lt;br /&gt;
## - Optimized Joomla! core SEF section&lt;br /&gt;
## - Bot filters and GZip optimization would never run for dynamic content&lt;br /&gt;
## - Content expiration optimization got more optimized&lt;br /&gt;
## - Added ETag rule&lt;br /&gt;
##&lt;br /&gt;
###############################################################################&lt;br /&gt;
&lt;br /&gt;
########## Begin - RewriteEngine enabled&lt;br /&gt;
RewriteEngine On&lt;br /&gt;
########## End - RewriteEngine enabled&lt;br /&gt;
&lt;br /&gt;
########## Begin - RewriteBase&lt;br /&gt;
#  Uncomment following line if your webserver&#039;s URL&lt;br /&gt;
#  is not directly related to physical file paths.&lt;br /&gt;
#  Update Your Joomla! Directory (just / for root)&lt;br /&gt;
&lt;br /&gt;
# RewriteBase /&lt;br /&gt;
########## End - RewriteBase&lt;br /&gt;
&lt;br /&gt;
########## Begin - No directory listings&lt;br /&gt;
## Note: +FollowSymlinks may cause problems and you might have to remove it&lt;br /&gt;
IndexIgnore *&lt;br /&gt;
Options +FollowSymLinks All -Indexes&lt;br /&gt;
########## End - No directory listings&lt;br /&gt;
&lt;br /&gt;
########## Begin - File execution order, by Komra.de&lt;br /&gt;
DirectoryIndex index.php index.html&lt;br /&gt;
########## End - File execution order&lt;br /&gt;
&lt;br /&gt;
########## Begin - ETag Optimization&lt;br /&gt;
## This rule will create an ETag for files based only on the modification&lt;br /&gt;
## timestamp and their size. This works wonders if you are using rsync&#039;ed&lt;br /&gt;
## servers, where the inode number of identical files differs.&lt;br /&gt;
## Note: It may cause problems on your server and you may need to remove it&lt;br /&gt;
FileETag MTime Size&lt;br /&gt;
########## End - ETag Optimization&lt;br /&gt;
&lt;br /&gt;
########## Begin - Optimal default expiration time&lt;br /&gt;
## Note: this might cause problems and you might have to comment it out by&lt;br /&gt;
## placing a hash in front of this section&#039;s lines&lt;br /&gt;
## Note: Some people prefer using &amp;quot;now plus 1 month&amp;quot; instead of &amp;quot;now plus 1 year&amp;quot;.&lt;br /&gt;
## Suit to taste.&lt;br /&gt;
&amp;lt;IfModule mod_expires.c&amp;gt;&lt;br /&gt;
        # Enable expiration control&lt;br /&gt;
        ExpiresActive On&lt;br /&gt;
&lt;br /&gt;
        # Default expiration: 1 hour after request&lt;br /&gt;
        ExpiresDefault &amp;quot;now plus 1 hour&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        # CSS and JS expiration: 1 week after request&lt;br /&gt;
        ExpiresByType text/css &amp;quot;now plus 1 week&amp;quot;&lt;br /&gt;
        ExpiresByType application/javascript &amp;quot;now plus 1 week&amp;quot;&lt;br /&gt;
        ExpiresByType application/x-javascript &amp;quot;now plus 1 week&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        # Image files expiration: 1 month after request&lt;br /&gt;
        ExpiresByType image/bmp &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/gif &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/jpeg &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/jp2 &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/pipeg &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/png &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/svg+xml &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/tiff &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/vnd.microsoft.icon &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/x-icon &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/ico &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/icon &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType text/ico &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType application/ico &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType image/vnd.wap.wbmp &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType application/vnd.wap.wbxml &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType application/smil &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        # Audio files expiration: 1 month after request&lt;br /&gt;
        ExpiresByType audio/basic &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/mid &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/midi &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/mpeg &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/x-aiff &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/x-mpegurl &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/x-pn-realaudio &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType audio/x-wav &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        &lt;br /&gt;
        # Movie files expiration: 1 month after request&lt;br /&gt;
        ExpiresByType application/x-shockwave-flash &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType x-world/x-vrml &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/x-msvideo &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/mpeg &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/mp4 &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/quicktime &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/x-la-asf &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
        ExpiresByType video/x-ms-asf &amp;quot;now plus 1 month&amp;quot;&lt;br /&gt;
&amp;lt;/IfModule&amp;gt;&lt;br /&gt;
########## End - Optimal expiration time&lt;br /&gt;
&lt;br /&gt;
########## Begin - Common hacking tools and bandwidth hoggers block&lt;br /&gt;
## By SigSiu.net and @nikosdion.&lt;br /&gt;
# This line also disables Akeeba Remote Control 2.5 and earlier&lt;br /&gt;
SetEnvIf user-agent &amp;quot;Indy Library&amp;quot; stayout=1&lt;br /&gt;
# WARNING: Disabling wget will also block the most common method for&lt;br /&gt;
# running CRON jobs. Remove if you have issues with CRON jobs.&lt;br /&gt;
SetEnvIf user-agent &amp;quot;Wget&amp;quot; stayout=1&lt;br /&gt;
# The following rules are for bandwidth-hogging download tools&lt;br /&gt;
SetEnvIf user-agent &amp;quot;libwww-perl&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;Download Demon&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;GetRight&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;GetWeb!&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;Go!Zilla&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;Go-Ahead-Got-It&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;GrabNet&amp;quot; stayout=1&lt;br /&gt;
SetEnvIf user-agent &amp;quot;TurnitinBot&amp;quot; stayout=1&lt;br /&gt;
# This line denies access to all of the above tools&lt;br /&gt;
deny from env=stayout&lt;br /&gt;
########## End - Common hacking tools and bandwidth hoggers block&lt;br /&gt;
&lt;br /&gt;
########## Begin - Automatic compression of resources&lt;br /&gt;
# Compress text, html, javascript, css, xml, kudos to Komra.de&lt;br /&gt;
# May kill access to your site for old versions of Internet Explorer&lt;br /&gt;
# The server needs to be compiled with mod_deflate otherwise it will send HTTP 500 Error.&lt;br /&gt;
# mod_deflate is not available on Apache 1.x series. Can only be used with Apache 2.x server.&lt;br /&gt;
# AddOutputFilterByType is now deprecated by Apache. Use mod_filter in the future.&lt;br /&gt;
AddOutputFilterByType DEFLATE text/plain text/html text/xml text/css application/xml application/xhtml+xml application/rss+xml application/javascript application/x-javascript&lt;br /&gt;
########## End - Automatic compression of resources&lt;br /&gt;
&lt;br /&gt;
########## Begin - Google Apps redirection, by Komra.de&lt;br /&gt;
## Uncomment the following line to enable:&lt;br /&gt;
# RewriteRule ^mail http://mail.google.com/a/example.com [R=301,L]&lt;br /&gt;
## If the above doesn&#039;t work on your server, try this:&lt;br /&gt;
## RewriteRule ^mail http://mail.google.com/a/example.com [R,L]&lt;br /&gt;
########## End - Google Apps redirection&lt;br /&gt;
&lt;br /&gt;
########## Begin - Redirect index.php to /&lt;br /&gt;
## Note: Change example.com to reflect your own domain&lt;br /&gt;
RewriteCond %{THE_REQUEST} !^POST&lt;br /&gt;
RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/&lt;br /&gt;
RewriteCond %{SERVER_PORT}&amp;gt;s ^(443&amp;gt;(s)|[0-9]+&amp;gt;s)$&lt;br /&gt;
RewriteRule ^index\.php$ http%2://www.example.com/$1 [R=301,L]&lt;br /&gt;
# If the above line throws a 500 error, try this instead:&lt;br /&gt;
# RewriteRule ^index\.php$ http%2://www.example.com/$1 [R,L]&lt;br /&gt;
########## End - Redirect index.php to /&lt;br /&gt;
&lt;br /&gt;
########## Begin - Redirect non-www to www&lt;br /&gt;
RewriteCond %{HTTP_HOST} !^www\. [NC]&lt;br /&gt;
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]&lt;br /&gt;
## If the above throws an HTTP 500 error, swap [R=301,L] with [R,L]&lt;br /&gt;
########## End - Redirect non-www to www&lt;br /&gt;
&lt;br /&gt;
########## Begin - Redirect www to non-www&lt;br /&gt;
## WARNING: Comment out the non-www to www rule if you choose to use this&lt;br /&gt;
# RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]&lt;br /&gt;
# RewriteRule ^(.*)$ http://%1/$1 [R=301,L]&lt;br /&gt;
## If the above throws an HTTP 500 error, swap [R=301,L] with [R,L]&lt;br /&gt;
########## End - Redirect non-www to www&lt;br /&gt;
&lt;br /&gt;
########## Begin - Redirect (www.)olddomain.com to www.example.com&lt;br /&gt;
## Note: olddomain.com is your old domain name, you want to redirect FROM,&lt;br /&gt;
## whereas www.example.com is the new domain name you want to redirect TO.&lt;br /&gt;
## Change those names to reflect your current configuration. Remember, this&lt;br /&gt;
## part of the file is supposed to be placed in www.olddomain.com!&lt;br /&gt;
## Note: Replace [R=301,L] with [R,L] if you get error 500.&lt;br /&gt;
## Uncomment the following lines to enable:&lt;br /&gt;
# RewriteCond %{HTTP_HOST} ^(www\.)?olddomain\.com [NC]&lt;br /&gt;
# RewriteRule (.*) http://www.example.com/$1 [R=301,L]&lt;br /&gt;
########## End - Redirect olddomain.com to www.example.com&lt;br /&gt;
&lt;br /&gt;
########## Begin - Force HTTPS for certain pages&lt;br /&gt;
# Force the page foobar.html to run in HTTPS mode, no matter what Joomla! says.&lt;br /&gt;
# This is a sample redirection for foobar.html. Do note that you have to change&lt;br /&gt;
# www.example.com to reflect your own domain. Remember to escape the dots using&lt;br /&gt;
# \. in the left hand side of each rule. You need BOTH LINES PER URL for the rule&lt;br /&gt;
# to work.&lt;br /&gt;
RewriteCond %{SERVER_PORT} !^443$&lt;br /&gt;
## Alternatively, comment the above line and uncomment the following line:&lt;br /&gt;
# RewriteCond %{HTTPS} ^off$ [NC]&lt;br /&gt;
RewriteRule ^foobar\.html$ https://www.example.com/foobar.html [R=301,L]&lt;br /&gt;
## NOTE: If you get an HTTP 500 error, please swap [R=301,L] with [R,L]&lt;br /&gt;
# Add more rules below this line&lt;br /&gt;
########## End - Force HTTPS for certain pages&lt;br /&gt;
&lt;br /&gt;
########## Begin - Rewrite rules to block out some common exploits&lt;br /&gt;
## If you experience problems on your site block out the operations listed below&lt;br /&gt;
## This attempts to block the most common type of exploit `attempts` to Joomla!&lt;br /&gt;
#&lt;br /&gt;
# If the request query string contains /proc/self/environ (by SigSiu.net)&lt;br /&gt;
RewriteCond %{QUERY_STRING} proc/self/environ [OR]&lt;br /&gt;
# Legacy variable injection (these attacks wouldn&#039;t work w/out Joomla! 1.5&#039;s Legacy Mode plugin)&lt;br /&gt;
RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|\%3D) [OR]&lt;br /&gt;
# Block out any script trying to base64_encode/base64_decode data to send via URL&lt;br /&gt;
RewriteCond %{QUERY_STRING} base64_(en|de)code\(.*\) [OR]&lt;br /&gt;
## IMPORTANT: If the above line throws an HTTP 500 error, replace it with these 2 lines:&lt;br /&gt;
# RewriteCond %{QUERY_STRING} base64_encode\(.*\) [OR]&lt;br /&gt;
# RewriteCond %{QUERY_STRING} base64_decode\(.*\) [OR]&lt;br /&gt;
# Block out any script that includes a &amp;lt;script&amp;gt; tag in URL&lt;br /&gt;
RewriteCond %{QUERY_STRING} (&amp;lt;|%3C).*script.*(&amp;gt;|%3E) [NC,OR]&lt;br /&gt;
# Block out any script trying to set a PHP GLOBALS variable via URL&lt;br /&gt;
RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]&lt;br /&gt;
# Block out any script trying to modify a _REQUEST variable via URL&lt;br /&gt;
RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})&lt;br /&gt;
# Return a 403 Forbidden header and show the content of the root homepage&lt;br /&gt;
RewriteRule .* index.php [F]&lt;br /&gt;
#&lt;br /&gt;
########## End - Rewrite rules to block out some common exploits&lt;br /&gt;
&lt;br /&gt;
########## Begin - File injection protection, by SigSiu.net&lt;br /&gt;
RewriteCond %{REQUEST_METHOD} GET&lt;br /&gt;
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=http:// [OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=(\.\.//?)+ [OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} [a-zA-Z0-9_]=/([a-z0-9_.]//?)+ [NC]&lt;br /&gt;
RewriteRule .* - [F]&lt;br /&gt;
########## End - File injection protection&lt;br /&gt;
&lt;br /&gt;
########## Begin - Advanced server protection rules exceptions ####&lt;br /&gt;
##&lt;br /&gt;
## These are sample exceptions to the Advanced Server Protection 3.0&lt;br /&gt;
## rule set further down this file.&lt;br /&gt;
##&lt;br /&gt;
## Allow UddeIM CAPTCHA&lt;br /&gt;
RewriteRule ^components/com_uddeim/captcha15\.php$ - [L]&lt;br /&gt;
## Allow Phil Taylor&#039;s Turbo Gears&lt;br /&gt;
RewriteRule ^plugins/system/GoogleGears/gears-manifest\.php$ - [L]&lt;br /&gt;
## Allow JoomlaWorks AllVideos&lt;br /&gt;
RewriteRule ^plugins/content/jw_allvideos/includes/jw_allvideos_scripts\.php$ - [L]&lt;br /&gt;
## Allow Admin Tools Joomla! updater to run&lt;br /&gt;
RewriteRule ^administrator/components/com_admintools/restore\.php$ - [L]&lt;br /&gt;
## Allow Akeeba Backup Professional&#039;s integrated restoration script to run&lt;br /&gt;
RewriteRule ^administrator/components/com_akeeba/restore\.php$ - [L]&lt;br /&gt;
## Allow Akeeba Kickstart&lt;br /&gt;
RewriteRule ^kickstart\.php$ - [L]&lt;br /&gt;
&lt;br /&gt;
# Add more rules to single PHP files here&lt;br /&gt;
&lt;br /&gt;
## Allow Agora attachments, but not PHP files in that directory!&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} !(\.php)$&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} -f&lt;br /&gt;
RewriteRule ^components/com_agora/img/members/ - [L]&lt;br /&gt;
&lt;br /&gt;
# Add more rules for allowing full access (except PHP files) on more directories here&lt;br /&gt;
&lt;br /&gt;
## Uncomment to allow full access to the cache directory (strongly not recommended!)&lt;br /&gt;
#RewriteRule ^cache/ - [L]&lt;br /&gt;
## Uncomment to allow full access to the tmp directory (strongly not recommended!)&lt;br /&gt;
#RewriteRule ^tmp/ - [L]&lt;br /&gt;
&lt;br /&gt;
# Add more full access rules here&lt;br /&gt;
&lt;br /&gt;
########## End - Advanced server protection rules exceptions ####&lt;br /&gt;
&lt;br /&gt;
########## Begin - Advanced server protection&lt;br /&gt;
# Advanced server protection, version 2.0 - August 2010&lt;br /&gt;
# by Nicholas K. Dionysopoulos&lt;br /&gt;
&lt;br /&gt;
## Referrer filtering for common media files. Replace with your own domain.&lt;br /&gt;
## This blocks most common fingerprinting attacks ;)&lt;br /&gt;
## Note: Change www\.example\.com with your own domain name, substituting the&lt;br /&gt;
## dots with \., i.e.: www\.example\.com for www.example.com&lt;br /&gt;
RewriteRule ^images/stories/.*\.(jp(e?g|2)?|png|gif|bmp|css|js|swf|ico)$ - [L]&lt;br /&gt;
RewriteCond %{HTTP_REFERER} .&lt;br /&gt;
RewriteCond %{HTTP_REFERER} !^https?://(www\.)?example\.com [NC]&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} -f&lt;br /&gt;
RewriteRule \.(jp(e?g|2)?|png|gif|bmp|css|js|swf|ico)$ - [F]&lt;br /&gt;
&lt;br /&gt;
## Disallow visual fingerprinting of Joomla! sites (module position dump)&lt;br /&gt;
## Initial idea by Brian Teeman and Ken Crowder, see:&lt;br /&gt;
## http://www.slideshare.net/brianteeman/hidden-joomla-secrets&lt;br /&gt;
## Improved by @nikosdion to work more efficiently and handle template&lt;br /&gt;
## and tmpl query parameters&lt;br /&gt;
RewriteCond %{QUERY_STRING} (^|&amp;amp;)tmpl=(component|system) [NC]&lt;br /&gt;
RewriteRule .* - [L]&lt;br /&gt;
RewriteCond %{QUERY_STRING} (^|&amp;amp;)t(p|emplate|mpl)= [NC]&lt;br /&gt;
RewriteRule .* - [F]&lt;br /&gt;
&lt;br /&gt;
## Disallow PHP Easter Eggs (can be used in fingerprinting attacks to determine&lt;br /&gt;
## your PHP version). See http://www.0php.com/php_easter_egg.php and&lt;br /&gt;
## http://osvdb.org/12184 for more information&lt;br /&gt;
RewriteCond %{QUERY_STRING} \=PHP[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12} [NC]&lt;br /&gt;
RewriteRule .* - [F]&lt;br /&gt;
&lt;br /&gt;
## Back-end protection&lt;br /&gt;
## This also blocks fingerprinting attacks browsing for XML and INI files&lt;br /&gt;
RewriteRule ^administrator/?$ - [L]&lt;br /&gt;
RewriteRule ^administrator/index\.(php|html?)$ - [L]&lt;br /&gt;
RewriteRule ^administrator/index[23]\.php$ - [L]&lt;br /&gt;
RewriteRule ^administrator/(components|modules|templates|images|plugins)/.*\.(jp(e?g|2)?|png|gif|bmp|css|js|swf|html?|mp(eg?|[34])|avi|wav|og[gv]|xlsx?|docx?|pptx?|zip|rar|pdf|xps|txt|7z|svg|od[tsp]|flv|mov)$ - [L]&lt;br /&gt;
RewriteRule ^administrator/ - [F]&lt;br /&gt;
&lt;br /&gt;
## Explicitly allow access only to XML-RPC&#039;s xmlrpc/index.php or plain xmlrpc/ directory&lt;br /&gt;
RewriteRule ^xmlrpc/(index\.php)?$ - [L]&lt;br /&gt;
RewriteRule ^xmlrpc/ - [F]&lt;br /&gt;
&lt;br /&gt;
## Disallow front-end access for certain Joomla! system directories&lt;br /&gt;
RewriteRule ^includes/js/ - [L]&lt;br /&gt;
RewriteRule ^(cache|includes|language|libraries|logs|tmp)/ - [F]&lt;br /&gt;
&lt;br /&gt;
## Allow limited access for certain Joomla! system directories with client-accessible content&lt;br /&gt;
RewriteRule ^(components|modules|plugins|templates)/.*\.(jp(e?g|2)?|png|gif|bmp|css|js|swf|html?|mp(eg?|[34])|avi|wav|og[gv]|xlsx?|docx?|pptx?|zip|rar|pdf|xps|txt|7z|svg|od[tsp]|flv|mov)$ - [L]&lt;br /&gt;
## Uncomment this line if you have extensions which require direct access to their own&lt;br /&gt;
## custom index.php files. Note that this is UNSAFE and the developer should be ashamed&lt;br /&gt;
## for being so lame, lazy and security unconscious.&lt;br /&gt;
# RewriteRule ^(components|modules|plugins|templates)/.*(index\.php)?$ - [L]&lt;br /&gt;
## Uncomment the following line if your template requires direct access to PHP files&lt;br /&gt;
## inside its directory, e.g. GZip compressed copies of its CSS files&lt;br /&gt;
# RewriteRule ^templates/.*\.php$ - [L]&lt;br /&gt;
RewriteRule ^(components|modules|plugins|templates)/ - [F]&lt;br /&gt;
&lt;br /&gt;
## Disallow access to rogue PHP files throughout the site, unless they are explicitly allowed&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} (\.php)$&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} !(/index[23]?\.php)$&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} -f&lt;br /&gt;
RewriteRule (.*\.php)$ - [F]&lt;br /&gt;
&lt;br /&gt;
## Disallow access to htaccess.txt and configuration.php-dist&lt;br /&gt;
RewriteRule ^(htaccess\.txt|configuration\.php-dist|php\.ini)$ - [F]&lt;br /&gt;
&lt;br /&gt;
## SQLi first line of defense, thanks to Radek Suski (SigSiu.net) @&lt;br /&gt;
## http://www.sigsiu.net/presentations/fortifying_your_joomla_website.html&lt;br /&gt;
## May cause problems on legitimate requests&lt;br /&gt;
RewriteCond %{QUERY_STRING} concat.*\( [NC,OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} union.*select.*\( [NC,OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} union.*all.*select.* [NC]&lt;br /&gt;
RewriteRule .* - [F]&lt;br /&gt;
&lt;br /&gt;
########## End - Advanced server protection&lt;br /&gt;
&lt;br /&gt;
########## Begin - Basic antispam Filter, by SigSiu.net&lt;br /&gt;
## I removed some common words, tweak to your liking&lt;br /&gt;
## This code uses PCRE and works only with Apache 2.x.&lt;br /&gt;
## This code will NOT work with Apache 1.x servers.&lt;br /&gt;
RewriteCond %{QUERY_STRING} \b(ambien|blue\spill|cialis|cocaine|ejaculation|erectile)\b [NC,OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} \b(erections|hoodia|huronriveracres|impotence|levitra|libido)\b [NC,OR]&lt;br /&gt;
RewriteCond %{QUERY_STRING} \b(lipitor|phentermin|pro[sz]ac|sandyauer|tramadol|troyhamby)\b [NC,OR]&lt;br /&gt;
## Note: The final RewriteCond must NOT use the [OR] flag.&lt;br /&gt;
RewriteCond %{QUERY_STRING} \b(ultram|unicauca|valium|viagra|vicodin|xanax|ypxaieo)\b [NC]&lt;br /&gt;
RewriteRule .* - [F]&lt;br /&gt;
## Note: The previous lines are a &amp;quot;compressed&amp;quot; version&lt;br /&gt;
## of the filters. You can add your own filters as:&lt;br /&gt;
## RewriteCond %{QUERY_STRING} \bbadword\b [NC,OR]&lt;br /&gt;
## where &amp;quot;badword&amp;quot; is the word you want to exclude&lt;br /&gt;
########## End - Basic antispam Filter, by SigSiu.net&lt;br /&gt;
&lt;br /&gt;
########## Begin - Joomla! core SEF Section&lt;br /&gt;
#&lt;br /&gt;
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]&lt;br /&gt;
# If the requested path and file is not /index.php and the request&lt;br /&gt;
# has not already been internally rewritten to the index.php script&lt;br /&gt;
RewriteCond %{REQUEST_URI} !^/index\.php&lt;br /&gt;
# and the request is for the site root, or for an extensionless URL,&lt;br /&gt;
# or the requested URL ends with one of the listed extensions&lt;br /&gt;
RewriteCond %{REQUEST_URI} /component/|(/[^.]*|\.(php|html?|feed|pdf|raw|ini|zip|json|file|vcf))$ [NC]&lt;br /&gt;
# and the requested path and file doesn&#039;t directly match a physical file&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} !-f&lt;br /&gt;
# and the requested path doesn&#039;t match a physical folder&lt;br /&gt;
RewriteCond %{REQUEST_FILENAME} !-d&lt;br /&gt;
# internally rewrite the request to the index.php script&lt;br /&gt;
RewriteRule .* index.php [L]&lt;br /&gt;
#&lt;br /&gt;
########## End - Joomla! core SEF Section&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
[http://perishablepress.com/press/tag/htaccess/ .htaccess tag archive @ perishablepress.com]&lt;br /&gt;
&lt;br /&gt;
[http://akeeba.assembla.com/code/master-htaccess/git/nodes/htaccess.txt Proposed &amp;quot;master htaccess&amp;quot; (updated by Nicholas on April 24th 2011 to v3.3) DO read the intro by Nicholas!]&lt;br /&gt;
[[Category:Security]]&lt;br /&gt;
&lt;br /&gt;
The original file contains a number of syntax errors, several rules that can never work, and a number of expressions that can be more efficiently coded.&lt;br /&gt;
&lt;br /&gt;
Bugs and enhancements originally discussed at: http://forum.joomla.org/viewtopic.php?f=432&amp;amp;t=549841&lt;br /&gt;
&lt;br /&gt;
Discussion also at: http://snipt.net/nikosdion/the-master-htaccess/ and http://snipt.net/g1smd/joomla-patch/&lt;br /&gt;
&lt;br /&gt;
The new proposed file: http://code.google.com/p/joomla-master-htaccess/source/list and at: http://akeeba.assembla.com/code/master-htaccess/git/node/logs&lt;br /&gt;
&lt;br /&gt;
The changes explained, line by line: &lt;br /&gt;
http://codereview.appspot.com/4312049/diff/1/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4290071/diff/1/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4290071/diff/8001/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4370051/diff/3/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4314051/diff/1001/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4430062/diff/1/joomla-master-htaccess.txt&lt;br /&gt;
http://codereview.appspot.com/4528051/diff/1/joomla-master-htaccess.txt&lt;/div&gt;</summary>
		<author><name>Ahmad</name></author>
	</entry>
	<entry>
		<id>https://docs.sandbox.joomla.org/index.php?title=J1.5_talk:Migrating_from_1.0.x_to_1.5_Stable&amp;diff=17520</id>
		<title>J1.5 talk:Migrating from 1.0.x to 1.5 Stable</title>
		<link rel="alternate" type="text/html" href="https://docs.sandbox.joomla.org/index.php?title=J1.5_talk:Migrating_from_1.0.x_to_1.5_Stable&amp;diff=17520"/>
		<updated>2009-11-12T13:06:15Z</updated>

		<summary type="html">&lt;p&gt;Ahmad: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Migrator link is broken&lt;br /&gt;
the new one is http://joomlacode.org/gf/download/frsrelease/7279/24909/migrator.zip&lt;br /&gt;
&lt;br /&gt;
Ahmad&lt;br /&gt;
----------&lt;br /&gt;
&lt;br /&gt;
Step One: A newer version of migrator available. Article says RC6, but 1.0 Stable available http://joomlacode.org/gf/download/frsrelease/7279/24909/migrator.zip&lt;br /&gt;
&lt;br /&gt;
ot2sen&lt;br /&gt;
-------------&lt;br /&gt;
Suggest an addition to the documentation that if a third party plugin does not show up in the list after uploading, check the permissions on /administrator/components/com_migrator/plugins/ (should be 777) at the same time, check the dumps directory for the same permissions.&lt;br /&gt;
&lt;br /&gt;
john abbott&lt;br /&gt;
-------------&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Looking into the code of a migrator plugin - especially the basic ones (this is the kind 99% of the novice users would need) - it appears this is very simple to code. I would like to add a little article on how to create a basic migrator plugin.&lt;br /&gt;
&lt;br /&gt;
For this, I&#039;d start from 2 addons used in the component already (for core tables): the poll_data plugin (no transformation of the data - just adaption to the UTF) and the content plugin (the most complicated one in the core set).&lt;br /&gt;
&lt;br /&gt;
A walk-through of these two plug-ins would help a lot of people to create their own plugins...&lt;br /&gt;
&lt;br /&gt;
Here&#039;s what I&#039;ve got already:&lt;br /&gt;
&lt;br /&gt;
Third-party add-ons for the migrator component&lt;br /&gt;
&lt;br /&gt;
== Assumptions... ==&lt;br /&gt;
&lt;br /&gt;
If you got to this page, I&#039;ll be assuming a few things: for starters you&#039;re familiar with the great Migrator component. You&#039;ll find more about this component on Pasamio Project&#039;s FRS site.&lt;br /&gt;
You&#039;ve probably been using it to migrate a site to Joomla 1.5.x … and I might assume that you bumped into some tables that weren&#039;t migrated because the add-on was missing...&lt;br /&gt;
Furthermore, I&#039;ll be assuming that you know some elementary PHP, SQL and the basics of the Joomla framework (mostly Joomla 1.0). This hand-out is meant for all of us (I&#039;m inclusing myself in here) who wrote some tiny little component in Joomla 1.0, and now want to make the leap to 1.5 – but already have a load of SQL data they don&#039;t want to manually input again (possibly on half a dozen sites).&lt;br /&gt;
My last assumption is that you&#039;re too lazy too do all the manual work... and you&#039;d prefer some simple script doing it for you.&lt;br /&gt;
In the examples, we&#039;ll be assuming default settings too... if you&#039;ve changed them, you&#039;ll know.&lt;br /&gt;
&lt;br /&gt;
== Why not? ==&lt;br /&gt;
&lt;br /&gt;
On almost every forum out there tackling Joomla, you&#039;ll find one or another posting complaining about the lack of a migrator add-on for this or another component out there. Probably the most important reason for those add-ons not being there, is because there&#039;s no simple step-by-step tutorial out here (on the web).&lt;br /&gt;
There are a few (more technical) explanations out there, that go into the deeps of the mechanics of the migrator component... but for me they rather scared me away than encourage me to look into it.&lt;br /&gt;
But that was until today: today I actually opened the code... and looked into the “plugins” folder of the component. Then I ordered them according to file size, and opened the tinyest one of them: Wow man! This is really easy!!&lt;br /&gt;
The easy approach: it&#039;s a “black box”&lt;br /&gt;
So what this component actually does in all its nitty gritty details? I don&#039;t have to know that. All I need to know is: what should I feed it, so it burps out a nice great Joomla 1.5 compatible SQL result?&lt;br /&gt;
&lt;br /&gt;
== First example: nothing changes... ==&lt;br /&gt;
&lt;br /&gt;
I guess for over 99% of the components out there, the SQL tables won&#039;t need to change if you migrate the component (not talking about the code here... just the content) I don&#039;t think this can get much easier... except maybe if the component itself would automatically migrate all tables without plugin in this manner... &lt;br /&gt;
We&#039;ll have a look at “poll_data.php” – the plugin that migrates the data for the polls. This data can be found in the table jos_poll_data. &lt;br /&gt;
The code actually starts at line 20 with the definition of a class.&lt;br /&gt;
Next we&#039;re defining some key variables.&lt;br /&gt;
&lt;br /&gt;
(etc...)&lt;br /&gt;
&lt;br /&gt;
== Second example: big changes are needed... ==&lt;br /&gt;
&lt;br /&gt;
Maybe this part would even be out of my league... but once it&#039;s in place, I&#039;m sure others will append to it.&lt;br /&gt;
&lt;br /&gt;
--[[User:Jurgentje|Jurgen.]] 21:51, 2 January 2009 (UTC)&lt;br /&gt;
&lt;br /&gt;
== New link for &amp;quot;Further information&amp;quot; section ==&lt;br /&gt;
&lt;br /&gt;
Suggest adding this link&lt;br /&gt;
[http://forum.joomla.org/viewtopic.php?p=1874666#p1874666 Guide for migrating to Joomla 1.5 with Agora Forum]&lt;/div&gt;</summary>
		<author><name>Ahmad</name></author>
	</entry>
</feed>