aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorVirtualTam <virtualtam+github@flibidi.net>2018-02-05 18:21:59 +0100
committerGitHub <noreply@github.com>2018-02-05 18:21:59 +0100
commit8b48e36594394e367cbb33c7ad1a679ea57c374d (patch)
tree5e0671ed51d327b755cd90de449fd3e9463404bd
parent91f17fc92a7168e2baf1096910b8f44f3a24a8a2 (diff)
parentcabf1b6becbc0143f6a9d0d6846fd948c06b5a64 (diff)
downloadShaarli-8b48e36594394e367cbb33c7ad1a679ea57c374d.tar.gz
Shaarli-8b48e36594394e367cbb33c7ad1a679ea57c374d.tar.zst
Shaarli-8b48e36594394e367cbb33c7ad1a679ea57c374d.zip
Merge pull request #1059 from virtualtam/fix/htaccess-git
htaccess: prevent accessing resources not managed by SCM
-rw-r--r--.htaccess8
1 files changed, 8 insertions, 0 deletions
diff --git a/.htaccess b/.htaccess
index 66ef8f69..19dd72a8 100644
--- a/.htaccess
+++ b/.htaccess
@@ -1,4 +1,12 @@
1# Disable directory listing
2Options -Indexes
3
1RewriteEngine On 4RewriteEngine On
5
6# Prevent accessing subdirectories not managed by SCM
7RewriteRule ^(.git|doxygen|vendor) - [F]
8
9# REST API
2RewriteCond %{REQUEST_FILENAME} !-f 10RewriteCond %{REQUEST_FILENAME} !-f
3RewriteCond %{REQUEST_FILENAME} !-d 11RewriteCond %{REQUEST_FILENAME} !-d
4RewriteRule ^ index.php [QSA,L] 12RewriteRule ^ index.php [QSA,L]