[TASK] Migrate LiveSearch to TypeScript
[Packages/TYPO3.CMS.git] / _.htaccess
index 910a643..03e8794 100644 (file)
@@ -281,14 +281,13 @@ AddDefaultCharset utf-8
        # IMPORTANT: This rule has to be the very first RewriteCond in order to work!
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
-       RewriteRule ^(.+)\.(\d+)\.(php|js|css|png|jpg|gif|gzip)$ $1.$3 [L]
+       RewriteRule ^(.+)\.(\d+)\.(php|js|css|png|jpg|gif|gzip)$ %{ENV:CWD}$1.$3 [L]
 
        # Access block for folders
        RewriteRule _(?:recycler|temp)_/ - [F]
        RewriteRule fileadmin/templates/.*\.(?:txt|ts)$ - [F]
-       RewriteRule typo3temp/var/ - [F]
-       RewriteRule ^(vendor|typo3_src) - [F]
-       RewriteRule (?:typo3conf/ext|typo3/sysext|typo3/ext)/[^/]+/(?:Configuration|Resources/Private|Tests?)/ - [F]
+       RewriteRule ^(?:vendor|typo3_src|typo3temp/var) - [F]
+       RewriteRule (?:typo3conf/ext|typo3/sysext|typo3/ext)/[^/]+/(?:Configuration|Resources/Private|Tests?|Documentation|docs?)/ - [F]
 
        # Block access to all hidden files and directories with the exception of
        # the visible content from within the `/.well-known/` hidden directory (RFC 5785).
@@ -299,7 +298,7 @@ AddDefaultCharset utf-8
 
        # Stop rewrite processing, if we are in the typo3/ directory or any other known directory
        # NOTE: Add your additional local storages here
-       RewriteRule (?:typo3/|fileadmin/|typo3conf/|typo3temp/|uploads/|favicon\.ico) - [L]
+       RewriteRule ^(?:typo3/|fileadmin/|typo3conf/|typo3temp/|uploads/|favicon\.ico) - [L]
 
        # If the file/symlink/directory does not exist => Redirect to index.php.
        # For httpd.conf, you need to prefix each '%{REQUEST_FILENAME}' with '%{DOCUMENT_ROOT}'.
@@ -311,19 +310,20 @@ AddDefaultCharset utf-8
 </IfModule>
 
 # Access block for files
-<FilesMatch "(?i:^\.|^#.*#|^(?:ChangeLog|ToDo|Readme|License)(?:\.md|\.txt)?|^composer\.(?:json|lock)|^ext_conf_template\.txt|^ext_typoscript_constants\.txt|^ext_typoscript_setup\.txt|flexform[^.]*\.xml|locallang[^.]*\.(?:xml|xlf)|\.(?:bak|co?nf|cfg|ya?ml|ts|dist|fla|in[ci]|log|sh|sql(?:\..*)?|sw[op]|git.*)|.*(?:~|rc))$">
-       # Apache < 2.3
-       <IfModule !mod_authz_core.c>
-               Order allow,deny
-               Deny from all
-               Satisfy All
-       </IfModule>
-
-       # Apache ≥ 2.3
-       <IfModule mod_authz_core.c>
-               Require all denied
-       </IfModule>
-</FilesMatch>
+# Apache < 2.3
+<IfModule !mod_authz_core.c>
+    <FilesMatch "(?i:^\.|^#.*#|^(?:ChangeLog|ToDo|Readme|License)(?:\.md|\.txt)?|^composer\.(?:json|lock)|^ext_conf_template\.txt|^ext_typoscript_constants\.txt|^ext_typoscript_setup\.txt|flexform[^.]*\.xml|locallang[^.]*\.(?:xml|xlf)|\.(?:bak|co?nf|cfg|ya?ml|ts|typoscript|dist|fla|in[ci]|log|sh|sql(?:\..*)?|sw[op]|git.*)|.*(?:~|rc))$">
+        Order allow,deny
+        Deny from all
+        Satisfy All
+    </FilesMatch>
+</IfModule>
+# Apache ≥ 2.3
+<IfModule mod_authz_core.c>
+    <If "%{REQUEST_URI} =~ m#(?i:/\.|/\x23.*\x23|/(?:ChangeLog|ToDo|Readme|License)(?:\.md|\.txt)?|/composer\.(?:json|lock)|/ext_conf_template\.txt|/ext_typoscript_constants\.txt|/ext_typoscript_setup\.txt|flexform[^.]*\.xml|locallang[^.]*\.(?:xml|xlf)|\.(?:bak|co?nf|cfg|ya?ml|ts|typoscript|dist|fla|in[ci]|log|sh|sql(?:\..*)?|sw[op]|git.*)|.*(?:~|rc))$#">
+        Require all denied
+    </If>
+</IfModule>
 
 # Block access to vcs directories
 <IfModule mod_alias.c>