Commit 652ec7d3 authored by Florian Schaal's avatar Florian Schaal

Merge branch 'stable-3.1' of git.ispconfig.org:ispconfig/ispconfig3 into stable-3.1

parents f86d6323 8e7dddea
......@@ -225,14 +225,14 @@ class installer_base {
global $conf;
//* check sql-mode
$check_sql_mode = $this->db->queryOneRecord("SELECT @@sql_mode");
/*$check_sql_mode = $this->db->queryOneRecord("SELECT @@sql_mode");
if ($check_sql_mode['@@sql_mode'] != '' && $check_sql_mode['@@sql_mode'] != 'NO_ENGINE_SUBSTITUTION') {
echo "Wrong SQL-mode. You should use NO_ENGINE_SUBSTITUTION. Add\n\n";
echo " sql-mode=\"NO_ENGINE_SUBSTITUTION\"\n\n";
echo"to the mysqld-section in your mysql-config on this server and restart mysqld afterwards\n";
die();
}
}*/
$unwanted_sql_plugins = array('validate_password');
$sql_plugins = $this->db->queryAllRecords("SELECT plugin_name FROM information_schema.plugins WHERE plugin_status='ACTIVE' AND plugin_name IN ?", $unwanted_sql_plugins);
......@@ -2093,7 +2093,12 @@ class installer_base {
$content = str_replace('{fpm_socket}', $fpm_socket, $content);
$content = str_replace('{cgi_socket}', $cgi_socket, $content);
if(file_exists('/var/run/php5-fpm.sock') || file_exists('/var/run/php/php7.0-fpm.sock')){
if( file_exists('/var/run/php5-fpm.sock')
|| file_exists('/var/run/php/php7.0-fpm.sock')
|| file_exists('/var/run/php/php7.1-fpm.sock')
|| file_exists('/var/run/php/php7.2-fpm.sock')
|| file_exists('/var/run/php/php7.3-fpm.sock')
){
$use_tcp = '#';
$use_socket = '';
} else {
......
This diff is collapsed.
......@@ -13338,7 +13338,7 @@ class SimplePie_Parse_Date
}
// Convert the number of seconds to an integer, taking decimals into account
$second = round($match[6] + $match[7] / pow(10, strlen($match[7])));
$second = @round($match[6] + $match[7] / @pow(10, strlen($match[7])));
return gmmktime($match[4], $match[5], $second, $match[2], $match[3], $match[1]) - $timezone;
}
......
......@@ -287,7 +287,7 @@ class page_action extends tform_actions {
unset($temp);
}
$fo_rec = '';
$fo_rec = array();
if (isset($this->dataRecord['dmarc_fo0'])) $fo_rec[] = '0';
if (isset($this->dataRecord['dmarc_fo1'])) $fo_rec[] = '1';
if (isset($this->dataRecord['dmarc_fod'])) $fo_rec[] = 'd';
......
......@@ -117,7 +117,7 @@ class app {
2 = ERROR
*/
function log($msg, $priority = 0) {
function log($msg, $priority = 0, $dblog = true) {
global $conf;
......@@ -148,7 +148,7 @@ class app {
fclose($fp);
// Log to database
if(isset($this->dbmaster)) {
if($dblog === true && isset($this->dbmaster)) {
$server_id = $conf['server_id'];
$loglevel = $priority;
$message = $msg;
......
......@@ -72,7 +72,13 @@ class cronjob_monitor_rkhunter extends cronjob {
/*
* Fetch the output
*/
$data['output'] = shell_exec('rkhunter --update --checkall --nocolors --skip-keypress');
// Do not try to update rkhunter on Debian and Ubuntu, rkhunter is keept up to date with apt.
if(file_exists('/etc/debian_version')) {
$data['output'] = shell_exec('rkhunter --checkall --nocolors --skip-keypress');
} else {
$data['output'] = shell_exec('rkhunter --update --checkall --nocolors --skip-keypress');
}
/*
* At this moment, there is no state (maybe later)
......
......@@ -476,7 +476,7 @@ class db
if($this->show_error_messages && $conf['demo_mode'] === false) {
echo $sErrormsg . $sAddMsg;
} elseif(is_object($app) && method_exists($app, 'log') && $bNoLog == false) {
$app->log($sErrormsg . $sAddMsg . ' -> ' . $mysql_errno . ' (' . $mysql_error . ')', LOGLEVEL_WARN);
$app->log($sErrormsg . $sAddMsg . ' -> ' . $mysql_errno . ' (' . $mysql_error . ')', LOGLEVEL_WARN, false);
} elseif(php_sapi_name() == 'cli') {
echo $sErrormsg . $sAddMsg;
}
......
......@@ -169,7 +169,12 @@ class apps_vhost_plugin {
//$content = str_replace('{fpm_port}', $web_config['php_fpm_start_port']+1, $content);
$content = str_replace('{fpm_socket}', $fpm_socket, $content);
$content = str_replace('{cgi_socket}', $cgi_socket, $content);
if(file_exists('/var/run/php5-fpm.sock') || file_exists('/var/run/php/php7.0-fpm.sock')){
if( file_exists('/var/run/php5-fpm.sock')
|| file_exists('/var/run/php/php7.0-fpm.sock')
|| file_exists('/var/run/php/php7.1-fpm.sock')
|| file_exists('/var/run/php/php7.2-fpm.sock')
|| file_exists('/var/run/php/php7.3-fpm.sock')
){
$use_tcp = '#';
$use_socket = '';
} else {
......
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