This repository has been archived by the owner on Dec 13, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 240
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(build): New version released 18.10.6
- Loading branch information
Showing
6 changed files
with
208 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,46 @@ | ||
#################### | ||
==================== | ||
Centreon Web 18.10.6 | ||
#################### | ||
==================== | ||
|
||
Enhancements | ||
------------ | ||
|
||
* [SNMP Trap] Increase size of special command field to text | ||
* [LDAP] Optimizing data sent when importing contact (#7559) | ||
* [Traps] Increase trap special command database field (#7610) | ||
* [Traps] Make @HOSTID@ macro available for trap configuration (#7592) | ||
* [UI] Enhance helper (tooltip) for mail configuration (#7584) | ||
* [UI] Translate notification delay parameters (#7696) | ||
* [Traps] You can create a trap with matching mode regexp (#7679) | ||
|
||
Bug fixes | ||
--------- | ||
|
||
* [Installation] Missing template directory in tar.gz package | ||
* [Centcore] Issue fixed with commands that were overwritten (#7650) | ||
* [Remote Server] Do not compare bugfix version on task import (#7638) | ||
* [Remote Server] Set task in failed if an error appears during import/export (#7634) | ||
* [Remote Server] Increase size of database field to store large FQDN (#7637 closes #7615) | ||
* [Remote Server] Update only properties of selected poller (#7633) | ||
* [Monitoring] Correctly display services with special character "+" (#7624) | ||
* [Configuration] Correctly search services by "disabled" state (#7612) | ||
* [Downtime] Correctly compute downtime duration & end date (#7601) | ||
* [Event Logs] Several issues fixed on CSV export (group arrows, host filter) | ||
* [Configuration] Correctly save service_interleave_factor value in Engine configuration form (#7591) | ||
* [Reporting] Correctly apply ACL on reporting dashboard (#7604) | ||
* [UI] Add scrollbar to remote server configuration wizard (#7600) | ||
* [UI] Change icon cursor when exporting graphs to PNG (#7613) | ||
* [Upgrade] Execute again missing PHP update from 2.8.27 (#7434) | ||
* [Upgrade] add missing upgrade script for 2.8.28 | ||
|
||
Documentation | ||
------------- | ||
|
||
* [Onboarding] Improve actual content for Quick Start and add more (#7609) | ||
|
||
Security fixes | ||
-------------- | ||
|
||
Technical | ||
--------- | ||
* [UI] add escapeshellarg to nagios_bin binary passed to shell_exec (#7694 closes CVE-2019-13024) | ||
|
||
Known issue | ||
----------- | ||
|
||
----------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,46 @@ | ||
#################### | ||
==================== | ||
Centreon Web 18.10.6 | ||
#################### | ||
==================== | ||
|
||
Enhancements | ||
------------ | ||
|
||
* [SNMP Trap] Increase size of special command field to text | ||
* [LDAP] Optimizing data sent when importing contact (#7559) | ||
* [Traps] Increase trap special command database field (#7610) | ||
* [Traps] Make @HOSTID@ macro available for trap configuration (#7592) | ||
* [UI] Enhance helper (tooltip) for mail configuration (#7584) | ||
* [UI] Translate notification delay parameters (#7696) | ||
* [Traps] You can create a trap with matching mode regexp (#7679) | ||
|
||
Bug fixes | ||
--------- | ||
|
||
* [Installation] Missing template directory in tar.gz package | ||
* [Centcore] Issue fixed with commands that were overwritten (#7650) | ||
* [Remote Server] Do not compare bugfix version on task import (#7638) | ||
* [Remote Server] Set task in failed if an error appears during import/export (#7634) | ||
* [Remote Server] Increase size of database field to store large FQDN (#7637 closes #7615) | ||
* [Remote Server] Update only properties of selected poller (#7633) | ||
* [Monitoring] Correctly display services with special character "+" (#7624) | ||
* [Configuration] Correctly search services by "disabled" state (#7612) | ||
* [Downtime] Correctly compute downtime duration & end date (#7601) | ||
* [Event Logs] Several issues fixed on CSV export (group arrows, host filter) | ||
* [Configuration] Correctly save service_interleave_factor value in Engine configuration form (#7591) | ||
* [Reporting] Correctly apply ACL on reporting dashboard (#7604) | ||
* [UI] Add scrollbar to remote server configuration wizard (#7600) | ||
* [UI] Change icon cursor when exporting graphs to PNG (#7613) | ||
* [Upgrade] Execute again missing PHP update from 2.8.27 (#7434) | ||
* [Upgrade] add missing upgrade script for 2.8.28 | ||
|
||
Documentation | ||
------------- | ||
|
||
* [Onboarding] Improve actual content for Quick Start and add more (#7609) | ||
|
||
Security fixes | ||
-------------- | ||
|
||
Technical | ||
--------- | ||
* [UI] add escapeshellarg to nagios_bin binary passed to shell_exec (#7694 closes CVE-2019-13024) | ||
|
||
Known issue | ||
----------- | ||
|
||
----------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,138 @@ | ||
<?php | ||
/* | ||
* Copyright 2005-2019 Centreon | ||
* Centreon is developed by : Julien Mathis and Romain Le Merlus under | ||
* GPL Licence 2.0. | ||
* | ||
* This program is free software; you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software | ||
* Foundation ; either version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY | ||
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A | ||
* PARTICULAR PURPOSE. See the GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License along with | ||
* this program; if not, see <http://www.gnu.org/licenses>. | ||
* | ||
* Linking this program statically or dynamically with other modules is making a | ||
* combined work based on this program. Thus, the terms and conditions of the GNU | ||
* General Public License cover the whole combination. | ||
* | ||
* As a special exception, the copyright holders of this program give Centreon | ||
* permission to link this program with independent modules to produce an executable, | ||
* regardless of the license terms of these independent modules, and to copy and | ||
* distribute the resulting executable under terms of Centreon choice, provided that | ||
* Centreon also meet, for each linked independent module, the terms and conditions | ||
* of the license of that module. An independent module is a module which is not | ||
* derived from this program. If you modify this program, you may extend this | ||
* exception to your version of the program, but you are not obliged to do so. If you | ||
* do not wish to do so, delete this exception statement from your version. | ||
* | ||
* For more information : contact@centreon.com | ||
* | ||
* | ||
*/ | ||
|
||
/* | ||
* Redo all PHP upgrades from 2.8.26 to 18.10.0 for people migrating from 2.8.27 before PR #7416 | ||
*/ | ||
$result = $pearDB->query( | ||
"SELECT `value` FROM `informations` WHERE `key` IN ('appKey', 'isRemote', 'isCentral')" | ||
); | ||
|
||
if ($result->rowCount() == 0) { | ||
$uniqueKey = md5(uniqid(rand(), true)); | ||
$pearDB->query( | ||
"INSERT INTO `informations` (`key`,`value`) VALUES ('appKey', '" . $uniqueKey . "')" | ||
); | ||
$pearDB->query( | ||
"INSERT INTO `informations` (`key`,`value`) VALUES ('isRemote', 'no')" | ||
); | ||
$pearDB->query( | ||
"INSERT INTO `informations` (`key`,`value`) VALUES ('isCentral', 'no')" | ||
); | ||
} | ||
|
||
// Retrieve current Nagios plugins path. | ||
$result = $pearDB->query( | ||
"SELECT value FROM options WHERE `key`='nagios_path_plugins'" | ||
); | ||
$row = $result->fetch(); | ||
|
||
// Update to new path if necessary. | ||
if ($row | ||
&& preg_match('#/usr/lib/nagios/plugins/?#', $row['value']) | ||
&& is_dir('/usr/lib64/nagios/plugins') | ||
) { | ||
// options table. | ||
$pearDB->query( | ||
"UPDATE options SET value='/usr/lib64/nagios/plugins/' WHERE `key`='nagios_path_plugins'" | ||
); | ||
|
||
// USER1 resource. | ||
$pearDB->query( | ||
"UPDATE cfg_resource SET resource_line='/usr/lib64/nagios/plugins' " . | ||
"WHERE resource_line='/usr/lib/nagios/plugins'" | ||
); | ||
} | ||
|
||
/* | ||
* fix menu acl when child is checked but its parent is not checked | ||
*/ | ||
|
||
// get all acl menu configurations | ||
$aclTopologies = $pearDB->query( | ||
'SELECT acl_topo_id FROM acl_topology' | ||
); | ||
while ($aclTopology = $aclTopologies->fetch()) { | ||
$aclTopologyId = $aclTopology['acl_topo_id']; | ||
|
||
// get parents of topologies which are at least read only | ||
$statement = $pearDB->prepare( | ||
'SELECT t.topology_page, t.topology_id, t.topology_parent ' . | ||
'FROM acl_topology_relations atr, topology t ' . | ||
'WHERE acl_topo_id = :topologyId ' . | ||
'AND atr.topology_topology_id = t.topology_id ' . | ||
'AND atr.access_right IN (1,2) ' // read/write and read only | ||
); | ||
$statement->bindParam(':topologyId', $aclTopologyId, \PDO::PARAM_INT); | ||
$statement->execute(); | ||
$topologies = $statement->fetchAll(\PDO::FETCH_UNIQUE | \PDO::FETCH_ASSOC); | ||
|
||
// get missing parent topology relations | ||
$aclToInsert = []; | ||
foreach ($topologies as $topologyPage => $topologyParameters) { | ||
if (isset($topologyParameters['topology_parent']) | ||
&& !isset($topologies[$topologyParameters['topology_parent']]) | ||
&& !in_array($topologyParameters['topology_parent'], $aclToInsert) | ||
) { | ||
if (strlen($topologyPage) === 5) { // level 3 | ||
$levelOne = substr($topologyPage, 0, 1); // get level 1 from beginning of topology_page | ||
if (!isset($aclToInsert[$levelOne])) { | ||
$aclToInsert[] = $levelOne; | ||
} | ||
$levelTwo = substr($topologyPage, 0, 3); // get level 2 from beginning of topology_page | ||
if (!isset($aclToInsert[$levelTwo])) { | ||
$aclToInsert[] = $levelTwo; | ||
} | ||
} elseif (strlen($topologyPage) === 3) { // level 2 | ||
$levelOne = substr($topologyPage, 0, 1); // get level 1 from beginning of topology_page | ||
if (!isset($aclToInsert[$levelOne])) { | ||
$aclToInsert[] = $levelOne; | ||
} | ||
} | ||
} | ||
} | ||
|
||
// insert missing parent topology relations | ||
if (count($aclToInsert)) { | ||
$statement = $pearDB->query( | ||
'INSERT INTO acl_topology_relations(acl_topo_id, topology_topology_id) ' . | ||
'SELECT ' . $aclTopologyId . ', t.topology_id ' . | ||
'FROM topology t ' . | ||
'WHERE t.topology_page IN (' . implode(',', $aclToInsert) . ')' | ||
); | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,12 @@ | ||
-- Change traps_execution_command from varchar(255) to text | ||
ALTER TABLE `traps` MODIFY COLUMN `traps_execution_command` text DEFAULT NULL; | ||
-- | ||
-- Change IP field from varchar(16) to varchar(255) | ||
-- | ||
ALTER TABLE `remote_servers` MODIFY COLUMN `ip` VARCHAR(255) NOT NULL; | ||
|
||
-- Add trap regexp matching | ||
ALTER TABLE `traps` ADD COLUMN IF NOT EXISTS `traps_mode` ENUM('0', '1') DEFAULT '0' AFTER `traps_oid`; | ||
|
||
-- Add trap filter | ||
ALTER TABLE `traps` MODIFY COLUMN `traps_exec_interval_type` ENUM('0','1','2','3') NULL DEFAULT '0'; |