Add base URL rewrite rules and secure petition data files
Add base URL rewrite rules for app routing Secure petition data files with access restrictions
This commit is contained in:
parent
93cfbea69a
commit
c50c4d481f
2 changed files with 21 additions and 0 deletions
14
content/.htaccess.base
Normal file
14
content/.htaccess.base
Normal file
|
|
@ -0,0 +1,14 @@
|
||||||
|
DirectorySlash Off
|
||||||
|
|
||||||
|
<IfModule mod_rewrite.c>
|
||||||
|
RewriteEngine On
|
||||||
|
RewriteBase /
|
||||||
|
|
||||||
|
# Route /app requests to index.php
|
||||||
|
RewriteCond %{REQUEST_URI} ^/app/
|
||||||
|
RewriteRule ^(.*)$ /index.php [L,QSA]
|
||||||
|
|
||||||
|
# Don't rewrite if file exists
|
||||||
|
RewriteCond %{REQUEST_FILENAME} !-f
|
||||||
|
RewriteRule ^(.*)$ /index.php [L,QSA]
|
||||||
|
</IfModule>
|
||||||
7
custom/data/petitions/.htaccess
Normal file
7
custom/data/petitions/.htaccess
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
# Deny access to petition data files
|
||||||
|
<FilesMatch "\.csv$">
|
||||||
|
Require all denied
|
||||||
|
</FilesMatch>
|
||||||
|
|
||||||
|
# Also deny directory listing
|
||||||
|
Options -Indexes
|
||||||
Loading…
Add table
Add a link
Reference in a new issue