Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion shopware/core/6.4/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -36,8 +40,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
8 changes: 7 additions & 1 deletion shopware/core/6.6/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -36,8 +40,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
8 changes: 7 additions & 1 deletion shopware/core/6.7/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -37,8 +41,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
8 changes: 7 additions & 1 deletion shopware/platform/6.4/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -36,8 +40,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
8 changes: 7 additions & 1 deletion shopware/platform/6.6/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -36,8 +40,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
8 changes: 7 additions & 1 deletion shopware/platform/6.7/public/.htaccess.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ DirectoryIndex index.php
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^index\.php(?:/(.*)|$) %{ENV:BASE}/$1 [R=301,L]

# Restrict stored HTML without affecting responses rendered by the application.
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(?:media|thumbnail)/.*\.(?i:html)$ - [E=SHOPWARE_STATIC_HTML:1]

# If the requested filename exists, simply serve it.
# We only want to let Apache serve files and not directories.
RewriteCond %{REQUEST_FILENAME} -f
Expand All @@ -37,8 +41,10 @@ DirectoryIndex index.php
</IfModule>

<IfModule mod_headers.c>
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'" env=SHOPWARE_STATIC_HTML

<FilesMatch "\.(?i:svg)$">
Header set Content-Security-Policy "script-src 'none'"
Header set Content-Security-Policy "script-src 'none'; object-src 'none'; frame-src 'none'; base-uri 'none'; form-action 'none'"
</FilesMatch>
</IfModule>

Expand Down
Loading