Commit 99cb22d7 authored by tbrehm's avatar tbrehm

- Changed default root for websites from /var/clients to /var/www/clients.

- Added deny directives to prevent direct access to the /var/www/clients and /var/www/domain.tld directories.
parent a29914f4
......@@ -7,4 +7,10 @@
LogFormat "%v %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined_ispconfig
CustomLog "| /usr/sbin/vlogger -s access.log -t \"%Y%m%d-access.log\" /var/log/ispconfig/httpd" combined_ispconfig
<Directory /var/www/clients>
AllowOverride None
Order Deny,Allow
Deny from all
</Directory>
......@@ -29,8 +29,8 @@ message_size_limit=0
getmail_config_dir=/etc/getmail
[web]
website_path=/var/clients/client[client_id]/web[website_id]
website_symlinks=/var/www/[website_domain]/:/var/clients/client[client_id]/[website_domain]/
website_path=/var/www/clients/client[client_id]/web[website_id]
website_symlinks=/var/www/[website_domain]/:/var/www/clients/client[client_id]/[website_domain]/
vhost_conf_dir=/etc/apache2/sites-available
vhost_conf_enabled_dir=/etc/apache2/sites-enabled
......
......@@ -6,6 +6,12 @@
LogFormat "%v %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined_ispconfig
CustomLog "| /usr/sbin/vlogger -s access.log -t \"%Y%m%d-access.log\" /var/log/ispconfig/httpd" combined_ispconfig
<Directory /var/www/clients>
AllowOverride None
Order Deny,Allow
Deny from all
</Directory>
<tmpl_loop name="ip_adresses">
NameVirtualHost {tmpl_var name="ip_address"}:80
NameVirtualHost {tmpl_var name="ip_address"}:443
......
<Directory /var/www/{tmpl_var name='domain'}>
AllowOverride None
Order Deny,Allow
Deny from all
</Directory>
<VirtualHost <tmpl_var name='ip_address'>:80>
<tmpl_if name='php' op='==' value='suphp'>
DocumentRoot <tmpl_var name='web_document_root'>
......@@ -27,7 +33,7 @@
ErrorDocument 500 /error/500.html
ErrorDocument 503 /error/503.html
</tmpl_if>
<Directory {tmpl_var name='web_document_root_www'}>
Options FollowSymLinks
AllowOverride Indexes AuthConfig Limit FileInfo
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment