Skip to content

Commit cc11f41

Browse files
committed
Added apache 2.4 support to .htaccess files.
1 parent 9b41f97 commit cc11f41

File tree

2 files changed

+23
-6
lines changed

2 files changed

+23
-6
lines changed

data/.htaccess

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,8 @@
1-
Deny from all
1+
<IfModule mod_authz_core.c> # Apache 2.4
2+
Require all denied
3+
</IfModule>
4+
<IfModule ! mod_authz_core.c> # Apache 2.2
5+
Deny from all
6+
</IfModule>
7+
28
Options -Indexes

data/media/.htaccess

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,18 @@
1-
Allow from all
2-
Options -Indexes
1+
<IfModule mod_authz_core.c> # Apache 2.4
2+
Require all granted
3+
</IfModule>
4+
<IfModule ! mod_authz_core.c> # Apache 2.2
5+
Allow from all
6+
</IfModule>
37

48
<Files *.php>
5-
Order Deny,Allow
6-
Deny from all
7-
</Files>
9+
<IfModule mod_authz_core.c> # Apache 2.4
10+
Require all denied
11+
</IfModule>
12+
<IfModule ! mod_authz_core.c> # Apache 2.2
13+
Deny from all
14+
Order Deny,Allow
15+
</IfModule>
16+
</Files>
17+
18+
Options -Indexes

0 commit comments

Comments
 (0)