John Berninger 5247492
Alias /wordpress /usr/share/wordpress
John Berninger 5247492
3b6aed1
# Access is only allowed via local access
3b6aed1
# Change this once configured
3b6aed1
John Berninger 5247492
<Directory /usr/share/wordpress>
John Berninger 5247492
  AllowOverride Options
b25e975
  <IfModule mod_authz_core.c>
b25e975
    # Apache 2.4
b25e975
    Require local
b25e975
  </IfModule>
b25e975
  <IfModule !mod_authz_core.c>
b25e975
    # Apache 2.2
b25e975
    Order Deny,Allow
b25e975
    Deny from All
b25e975
    Allow from 127.0.0.1
b25e975
    Allow from ::1
b25e975
 </IfModule>
John Berninger 5247492
</Directory>
240dbed
3b6aed1
<Directory /usr/share/wordpress/wp-content/uploads>
3b6aed1
  # Deny access to any php file in the uploads directory
3784ddd
  <FilesMatch "\.(php|phar)$">
3b6aed1
    Order Deny,Allow
3b6aed1
    Deny from all
3b6aed1
  </FilesMatch>
3b6aed1
</Directory>
3b6aed1
240dbed
<Directory /usr/share/wordpress/wp-content/plugins/akismet>
3b6aed1
  # Deny access to any php file in the akismet directory
240dbed
  <FilesMatch "\.(php|txt)$">
240dbed
    Order Deny,Allow
240dbed
    Deny from all
240dbed
  </FilesMatch>
240dbed
</Directory>