#-----------------------------------------------#
# Начало блока конфигурации HTTP хоста
#-----------------------------------------------#

<VirtualHost *:%httpport%>

    DocumentRoot    "%hostdir%"
    ServerName      "%host%"
    ServerAlias     "%host%" %aliases%
    ScriptAlias     /cgi-bin/ "%hostdir%/cgi-bin/"
    php_admin_value mbstring.func_overload 2

</VirtualHost>

#-----------------------------------------------#
# Конец блока конфигурации HTTP хоста
#-----------------------------------------------#

#-----------------------------------------------#
# Начало блока конфигурации HTTPS хоста
#-----------------------------------------------#

<IfModule ssl_module>
<VirtualHost *:%httpsport%>

    DocumentRoot    "%hostdir%"
    ServerName      "%host%"
    ServerAlias     "%host%" %aliases%
    ScriptAlias     /cgi-bin/ "%hostdir%/cgi-bin/"

    SSLEngine       on
    #Header always set          Strict-Transport-Security "max-age=94608000"

    #SSLCACertificateFile       ""
    #SSLCertificateChainFile    ""

    SSLCertificateFile          "%sprogdir%/userdata/config/cert_files/server.crt"
    SSLCertificateKeyFile       "%sprogdir%/userdata/config/cert_files/server.key"

    SetEnvIf User-Agent ".*MSIE [1-5].*" \
    nokeepalive ssl-unclean-shutdown \
    downgrade-1.0 force-response-1.0

    SetEnvIf User-Agent ".*MSIE [6-9].*" \
    ssl-unclean-shutdown

    <FilesMatch "\.(cgi|shtml|phtml|php)$">
        SSLOptions              +StdEnvVars
    </FilesMatch>

    <Directory "%hostdir%/cgi-bin/">
        SSLOptions              +StdEnvVars
    </Directory>

</VirtualHost>
</IfModule>

#-----------------------------------------------#
# Конец блока конфигурации HTTPS хоста
#-----------------------------------------------#
