fix ssl-procotols in apache-cron; fix files-match regex in apache-cron
Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>
This commit is contained in:
@@ -331,10 +331,10 @@ class apache extends HttpConfigBase
|
|||||||
$extensions = explode(" ", $filesmatch);
|
$extensions = explode(" ", $filesmatch);
|
||||||
$filesmatch = "";
|
$filesmatch = "";
|
||||||
foreach ($extensions as $ext) {
|
foreach ($extensions as $ext) {
|
||||||
$filesmatch .= $ext.'|';
|
$filesmatch .= substr($ext, 1).'|';
|
||||||
}
|
}
|
||||||
// start block, cut off last pipe and close block
|
// start block, cut off last pipe and close block
|
||||||
$filesmatch = '('.substr($filesmatch, -1).')';
|
$filesmatch = '('.substr($filesmatch, 0, -1).')';
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' <FilesMatch \.'.$filesmatch.'$>'. "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' <FilesMatch \.'.$filesmatch.'$>'. "\n";
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' SetHandler proxy:unix:' . $php->getInterface()->getSocketFile() . '|fcgi://localhost' . "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' SetHandler proxy:unix:' . $php->getInterface()->getSocketFile() . '|fcgi://localhost' . "\n";
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' </FilesMatch>' . "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' </FilesMatch>' . "\n";
|
||||||
@@ -462,7 +462,7 @@ class apache extends HttpConfigBase
|
|||||||
} else {
|
} else {
|
||||||
|
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' SSLEngine On' . "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' SSLEngine On' . "\n";
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' SSLProtocol -ALL' . str_replace(","," +", Settings::Get('system.ssl_protocols')) . "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' SSLProtocol -ALL +' . str_replace(","," +", Settings::Get('system.ssl_protocols')) . "\n";
|
||||||
if (Settings::Get('system.apache24') == '1') {
|
if (Settings::Get('system.apache24') == '1') {
|
||||||
if (Settings::Get('system.http2_support') == '1') {
|
if (Settings::Get('system.http2_support') == '1') {
|
||||||
$this->virtualhosts_data[$vhosts_filename] .= ' Protocols h2 http/1.1' . "\n";
|
$this->virtualhosts_data[$vhosts_filename] .= ' Protocols h2 http/1.1' . "\n";
|
||||||
@@ -900,7 +900,7 @@ class apache extends HttpConfigBase
|
|||||||
|
|
||||||
if ($domain['ssl_cert_file'] != '') {
|
if ($domain['ssl_cert_file'] != '') {
|
||||||
$vhost_content .= ' SSLEngine On' . "\n";
|
$vhost_content .= ' SSLEngine On' . "\n";
|
||||||
$vhost_content .= ' SSLProtocol -ALL' . str_replace(","," +", Settings::Get('system.ssl_protocols')) . "\n";
|
$vhost_content .= ' SSLProtocol -ALL +' . str_replace(","," +", Settings::Get('system.ssl_protocols')) . "\n";
|
||||||
if (Settings::Get('system.apache24') == '1') {
|
if (Settings::Get('system.apache24') == '1') {
|
||||||
if (isset($domain['http2']) && $domain['http2'] == '1') {
|
if (isset($domain['http2']) && $domain['http2'] == '1') {
|
||||||
$vhost_content .= ' Protocols h2 http/1.1' . "\n";
|
$vhost_content .= ' Protocols h2 http/1.1' . "\n";
|
||||||
|
|||||||
@@ -48,10 +48,10 @@ class apache_fcgid extends apache
|
|||||||
$extensions = explode(" ", $filesmatch);
|
$extensions = explode(" ", $filesmatch);
|
||||||
$filesmatch = "";
|
$filesmatch = "";
|
||||||
foreach ($extensions as $ext) {
|
foreach ($extensions as $ext) {
|
||||||
$filesmatch .= $ext.'|';
|
$filesmatch .= substr($ext, 1).'|';
|
||||||
}
|
}
|
||||||
// start block, cut off last pipe and close block
|
// start block, cut off last pipe and close block
|
||||||
$filesmatch = '('.substr($filesmatch, -1).')';
|
$filesmatch = '('.substr($filesmatch, 0, -1).')';
|
||||||
$php_options_text.= ' <FilesMatch \.'.$filesmatch.'$>'. "\n";
|
$php_options_text.= ' <FilesMatch \.'.$filesmatch.'$>'. "\n";
|
||||||
$php_options_text.= ' SetHandler proxy:unix:' . $php->getInterface()->getSocketFile() . '|fcgi://localhost'. "\n";
|
$php_options_text.= ' SetHandler proxy:unix:' . $php->getInterface()->getSocketFile() . '|fcgi://localhost'. "\n";
|
||||||
$php_options_text.= ' </FilesMatch>' . "\n";
|
$php_options_text.= ' </FilesMatch>' . "\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user