Marius Cramer
2014-03-24 3bc1e1d998fe33dfd3905926e0f8566eda4cc852
Removed usage of AddHandler in apache vhost config
- Reason:
AddHandler fcgid-script .php
does not only parse .php files, but all .php.* (e. g. .php.txt, .php.test etc.)
4 files modified
47 ■■■■ changed files
install/tpl/apache_apps.vhost.master 4 ●●● patch | view | raw | blame | history
install/tpl/apache_ispconfig.vhost.master 4 ●●● patch | view | raw | blame | history
server/conf/apache_apps.vhost.master 4 ●●● patch | view | raw | blame | history
server/conf/vhost.conf.master 35 ●●●●● patch | view | raw | blame | history
install/tpl/apache_apps.vhost.master
@@ -36,7 +36,9 @@
    <Directory {tmpl_var name='apps_vhost_dir'}>
        Options +Indexes +FollowSymLinks +MultiViews +ExecCGI
        AllowOverride AuthConfig Indexes Limit Options FileInfo
        AddHandler fcgid-script .php
        <FilesMatch "\.php$">
          SetHandler fcgid-script
        </FilesMatch>
        FCGIWrapper {tmpl_var name='apps_vhost_basedir'}/php-fcgi-scripts/apps/.php-fcgi-starter .php
        <tmpl_if name='apache_version' op='>' value='2.2' format='version'>
        Require all granted
install/tpl/apache_ispconfig.vhost.master
@@ -20,7 +20,9 @@
    <Directory /var/www/ispconfig/>
      Options -Indexes +FollowSymLinks +MultiViews +ExecCGI
      AllowOverride AuthConfig Indexes Limit Options FileInfo
      AddHandler fcgid-script .php
      <FilesMatch "\.php$">
          SetHandler fcgid-script
      </FilesMatch>
      FCGIWrapper /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter .php
      <tmpl_if name='apache_version' op='>' value='2.2' format='version'>
      Require all granted
server/conf/apache_apps.vhost.master
@@ -36,7 +36,9 @@
    <Directory {tmpl_var name='apps_vhost_dir'}>
        Options +Indexes +FollowSymLinks +MultiViews +ExecCGI
        AllowOverride AuthConfig Indexes Limit Options FileInfo
        AddHandler fcgid-script .php
        <FilesMatch "\.php$">
            SetHandler fcgid-script
        </FilesMatch>
        FCGIWrapper {tmpl_var name='apps_vhost_basedir'}/php-fcgi-scripts/apps/.php-fcgi-starter .php
        <tmpl_if name='apache_version' op='>' value='2.2' format='version'>
        Require all granted
server/conf/vhost.conf.master
@@ -156,7 +156,9 @@
<tmpl_if name='python' op='==' value='y'>
        <IfModule mod_python.c>
            <Directory {tmpl_var name='web_document_root_www'}>
                AddHandler mod_python .py
                <FilesMatch "\.py$">
                    SetHandler mod_python
                </FilesMatch>
                PythonHandler mod_python.publisher
                PythonDebug On
            </Directory>
@@ -174,8 +176,9 @@
            </tmpl_if>
        </Directory>
        ScriptAlias  /cgi-bin/ <tmpl_var name='document_root'>/cgi-bin/
        AddHandler cgi-script .cgi
        AddHandler cgi-script .pl
        <FilesMatch "\.(cgi|pl)$">
            SetHandler cgi-script
        </FilesMatch>
</tmpl_if>
<tmpl_if name='suexec' op='==' value='y'>
        # suexec enabled
@@ -202,13 +205,15 @@
        # suphp enabled
        <Directory {tmpl_var name='web_document_root'}>
        <IfModule mod_suphp.c>
                suPHP_Engine on
                # suPHP_UserGroup <tmpl_var name='system_user'> <tmpl_var name='system_group'>
            suPHP_Engine on
            # suPHP_UserGroup <tmpl_var name='system_user'> <tmpl_var name='system_group'>
<tmpl_if name='has_custom_php_ini'>
    suPHP_ConfigPath <tmpl_var name='custom_php_ini_dir'>
</tmpl_if>
                AddHandler x-httpd-suphp .php .php3 .php4 .php5
                suPHP_AddHandler x-httpd-suphp
            <FilesMatch "\.php[345]?$">
                SetHandler x-httpd-suphp
            </FilesMatch>
            suPHP_AddHandler x-httpd-suphp
        </IfModule>
        </Directory>
</tmpl_if>
@@ -216,7 +221,9 @@
        # php as cgi enabled
        ScriptAlias /php5-cgi <tmpl_var name='cgi_starter_path'><tmpl_var name='cgi_starter_script'>
        Action php5-cgi /php5-cgi
        AddHandler php5-cgi .php .php3 .php4 .php5
        <FilesMatch "\.php[345]?$">
            SetHandler php5-cgi
        </FilesMatch>
        <Directory {tmpl_var name='cgi_starter_path'}>
            <tmpl_if name='apache_version' op='>' value='2.2' format='version'>
            Require all granted
@@ -253,7 +260,9 @@
</tmpl_if>
        </IfModule>
        <Directory {tmpl_var name='web_document_root_www'}>
                AddHandler fcgid-script .php .php3 .php4 .php5
                <FilesMatch "\.php[345]?$">
                    SetHandler fcgid-script
                </FilesMatch>
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php3
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php4
@@ -268,7 +277,9 @@
                </tmpl_if>
        </Directory>
        <Directory {tmpl_var name='web_document_root'}>
                AddHandler fcgid-script .php .php3 .php4 .php5
                <FilesMatch "\.php[345]?$">
                    SetHandler fcgid-script
                </FilesMatch>
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php3
                FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php4
@@ -293,7 +304,9 @@
                    Allow from all
                    </tmpl_if>
                </Directory>
                AddHandler php5-fcgi .php .php3 .php4 .php5
                <FilesMatch "\.php[345]?$">
                    SetHandler php5-fcgi
                </FilesMatch>
                Action php5-fcgi /php5-fcgi
                Alias /php5-fcgi {tmpl_var name='document_root'}/cgi-bin/php5-fcgi-{tmpl_var name='ip_address'}-{tmpl_var name='port'}-{tmpl_var name='domain'}
<tmpl_if name='use_tcp'>