From f0ff20fda1e33a5f231763bc3fc4ed7fe031e7a3 Mon Sep 17 00:00:00 2001 From: samucarc Date: Wed, 28 Nov 2018 21:38:02 +0100 Subject: [PATCH 1/9] Add commands alert --- pandora_console/include/functions_api.php | 59 +++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/pandora_console/include/functions_api.php b/pandora_console/include/functions_api.php index 3cc0e58a67..daada976bd 100644 --- a/pandora_console/include/functions_api.php +++ b/pandora_console/include/functions_api.php @@ -7625,6 +7625,65 @@ function api_set_alert_actions($id, $id2, $other, $trash1) { } } + +function api_set_alert_commands($id, $thrash2, $other, $trash1) { + global $config; + + $command = $other['data'][0]; + $id_group = $other['data'][1]; + $description = $other['data'][2]; + $internal = $other['data'][3]; + $fields_descriptions_decode = io_safe_output(base64_decode($other['data'][4], true)); + $fields_values_decode = io_safe_output(base64_decode($other['data'][5], true)); + + + if (defined ('METACONSOLE')) { + return; + } + + if (!check_acl($config['id_user'], 0, "LW")){ + returnError('forbidden', 'string'); + return; + } + + $name = db_get_value ('id', 'talert_commands', 'name', $id); + $group = db_get_value ('id_grupo', 'tgrupo', 'id_grupo', $id_group); + + if ($name) { + returnError('error_parameter', 'Name already exist'); + return; + } + + if (!$group && $id_group != 0) { + returnError('error_parameter', 'Group does not exist'); + return; + } + + if ($other['type'] == 'string') { + returnError('error_parameter', 'Error in the parameters.'); + return; + } + else if ($other['type'] == 'array') { + + + $values = array('name' => $id,'command' => $command, 'id_group' => $id_group, + 'description' => $description, 'internal' => $internal, 'fields_descriptions' => $fields_descriptions_decode, + 'fields_values' => $fields_values_decode); + + $return = db_process_sql_insert('talert_commands', $values); + + $data['type'] = 'string'; + if ($return === false) { + $data['data'] = 0; + } + else { + $data['data'] = $return; + } + returnData('string', $data); + return; + } +} + function api_set_new_event($trash1, $trash2, $other, $trash3) { $simulate = false; $time = get_system_time(); From dc7176585e33fb8af8377b7770df8a14a395d092 Mon Sep 17 00:00:00 2001 From: samucarc Date: Thu, 29 Nov 2018 16:57:17 +0100 Subject: [PATCH 2/9] new API get_all_alerts_command --- pandora_console/include/functions_api.php | 100 +++++++++++++++++++--- 1 file changed, 90 insertions(+), 10 deletions(-) diff --git a/pandora_console/include/functions_api.php b/pandora_console/include/functions_api.php index daada976bd..91024dea22 100644 --- a/pandora_console/include/functions_api.php +++ b/pandora_console/include/functions_api.php @@ -35,6 +35,7 @@ enterprise_include_once ('include/functions_events.php'); enterprise_include_once ('include/functions_agents.php'); enterprise_include_once ('include/functions_modules.php'); enterprise_include_once ('include/functions_clusters.php'); +enterprise_include_once ('include/functions_alerts.php'); /** * Parse the "other" parameter. @@ -4508,6 +4509,45 @@ function api_get_all_alert_templates($thrash1, $thrash2, $other, $thrash3) { } } +function api_get_all_alert_commands($thrash1, $thrash2, $other, $thrash3) { + global $config; + + if (defined ('METACONSOLE')) { + return; + } + + if (!isset($other['data'][0])) + $separator = ';'; // by default + else + $separator = $other['data'][0]; + + if (!check_acl($config["id_user"], 0, "LM")) { + returnError("forbidden", "csv"); + return; + } + + $commands = db_get_all_rows_filter( + 'talert_commands', + array('id_group' => array_keys(users_get_groups(false, "LM"))) + ); + +if ($commands === false) $commands = array (); + + if ($commands !== false) { + $data['type'] = 'array'; + $data['data'] = $commands; + } + + if (!$commands) { + returnError('error_get_all_alert_commands', + __('Error getting all alert commands.')); + } + else { + returnData('csv', $data, $separator); + } +} + + /** * Get an alert tamplate, and print the result like a csv. * @@ -7625,7 +7665,21 @@ function api_set_alert_actions($id, $id2, $other, $trash1) { } } +/** + * Create a new alert command + * @param $id as command name + * other= (optional). Are the following in this order: + * + * + * + * + * + * ... + example: + + *http://localhost/pandora_console/include/api.php?op=set&op2=alert_commands&id=PRUEBA1&other=command|0|Desc|1|des1|val1|des2|val2|des3|val3||val4|des5&other_mode=url_encode_separator_|&apipass=1234&user=admin&pass=pandora +*/ function api_set_alert_commands($id, $thrash2, $other, $trash1) { global $config; @@ -7633,9 +7687,6 @@ function api_set_alert_commands($id, $thrash2, $other, $trash1) { $id_group = $other['data'][1]; $description = $other['data'][2]; $internal = $other['data'][3]; - $fields_descriptions_decode = io_safe_output(base64_decode($other['data'][4], true)); - $fields_values_decode = io_safe_output(base64_decode($other['data'][5], true)); - if (defined ('METACONSOLE')) { return; @@ -7649,13 +7700,23 @@ function api_set_alert_commands($id, $thrash2, $other, $trash1) { $name = db_get_value ('id', 'talert_commands', 'name', $id); $group = db_get_value ('id_grupo', 'tgrupo', 'id_grupo', $id_group); + if ($id == '' || !$id) { + returnError('error_parameter', __('Name cannot be empty.')); + return; + } + + if ($command == '' || !$command) { + returnError('error_parameter', __('Command cannot be empty.')); + return; + } + if ($name) { - returnError('error_parameter', 'Name already exist'); + returnError('error_parameter', __('Name already exist')); return; } if (!$group && $id_group != 0) { - returnError('error_parameter', 'Group does not exist'); + returnError('error_parameter', __('Group does not exist')); return; } @@ -7665,12 +7726,31 @@ function api_set_alert_commands($id, $thrash2, $other, $trash1) { } else if ($other['type'] == 'array') { + $fields_descriptions = array(); + $fields_values = array(); + $max_macro_fields = $config['max_macro_fields'] * 2; + + $values = array(); + for ($i=0;$i<$max_macro_fields; $i++) { + $n = $i + 4; + + if (!$other['data'][$n]) + $other['data'][$n] = ''; + + if ($n%2==0) + $fields_descriptions[] = $other['data'][$n]; + else + $fields_values[] = $other['data'][$n]; + } + + $fields_descriptions_encode = io_json_mb_encode($fields_descriptions); + $fields_values_encode = io_json_mb_encode($fields_values); + + $values = array('id_group' => $id_group, + 'description' => $description, 'internal' => $internal, 'fields_descriptions' => $fields_descriptions_encode, + 'fields_values' => $fields_values_encode); - $values = array('name' => $id,'command' => $command, 'id_group' => $id_group, - 'description' => $description, 'internal' => $internal, 'fields_descriptions' => $fields_descriptions_decode, - 'fields_values' => $fields_values_decode); - - $return = db_process_sql_insert('talert_commands', $values); + $return = alerts_create_alert_command($id, $command, $values); $data['type'] = 'string'; if ($return === false) { From 517cb855476a262a87c0ca90e46647a746861e08 Mon Sep 17 00:00:00 2001 From: samucarc Date: Mon, 3 Dec 2018 17:38:57 +0100 Subject: [PATCH 3/9] Added new features in CLI to create and view alert commands --- pandora_console/include/functions_api.php | 18 ++-- pandora_server/lib/PandoraFMS/Core.pm | 18 ++++ pandora_server/lib/PandoraFMS/DB.pm | 11 +++ pandora_server/util/pandora_manage.pl | 106 +++++++++++++++++++++- 4 files changed, 144 insertions(+), 9 deletions(-) diff --git a/pandora_console/include/functions_api.php b/pandora_console/include/functions_api.php index 91024dea22..e302c66259 100644 --- a/pandora_console/include/functions_api.php +++ b/pandora_console/include/functions_api.php @@ -7667,14 +7667,14 @@ function api_set_alert_actions($id, $id2, $other, $trash1) { /** * Create a new alert command - * @param $id as command name - * other= (optional). Are the following in this order: + * @param $id as command name (optional) + * other= (mandatory). Are the following in this order: * - * - * - * - * - * ... + * (mandatory) + * (optional) + * (optional) + * (optional) + * ... (optional) example: @@ -7684,7 +7684,9 @@ function api_set_alert_commands($id, $thrash2, $other, $trash1) { global $config; $command = $other['data'][0]; - $id_group = $other['data'][1]; + $id_group = 0; + if ($other['data'][1] != '') + $id_group = $other['data'][1]; $description = $other['data'][2]; $internal = $other['data'][3]; diff --git a/pandora_server/lib/PandoraFMS/Core.pm b/pandora_server/lib/PandoraFMS/Core.pm index bcb08a23ae..d2045ae89a 100644 --- a/pandora_server/lib/PandoraFMS/Core.pm +++ b/pandora_server/lib/PandoraFMS/Core.pm @@ -163,6 +163,7 @@ our @EXPORT = qw( pandora_add_agent_address pandora_audit pandora_create_agent + pandora_create_alert_command pandora_create_group pandora_create_incident pandora_create_module @@ -2681,6 +2682,23 @@ sub pandora_delete_all_template_module_actions ($$) { return db_do ($dbh, 'DELETE FROM talert_template_module_actions WHERE id_alert_template_module = ?', $template_module_id); } +######################################################################## +=head2 C<< pandora_create_alert_command(I<$pa_config>, I<$parameters>, I<$dbh>) >> + +Create a alert command. + +=cut +######################################################################## +sub pandora_create_alert_command ($$$) { + my ($pa_config, $parameters, $dbh) = @_; + + logger($pa_config, "Creating alert command '$parameters->{'name'}'.", 10); + + my $command_id = db_process_insert($dbh, 'id', 'talert_commands', $parameters); + + return $command_id; +} + ######################################################################## =head2 C<< pandora_update_agent_address(I<$pa_config>, I<$agent_id>, I<$address>, I<$dbh>) >> diff --git a/pandora_server/lib/PandoraFMS/DB.pm b/pandora_server/lib/PandoraFMS/DB.pm index dc0622c98b..20bece94e6 100644 --- a/pandora_server/lib/PandoraFMS/DB.pm +++ b/pandora_server/lib/PandoraFMS/DB.pm @@ -62,6 +62,7 @@ our @EXPORT = qw( get_agent_module_id get_alert_template_module_id get_alert_template_name + get_command_id get_db_rows get_db_rows_limit get_db_single_row @@ -209,6 +210,16 @@ sub get_action_id ($$) { return defined ($rc) ? $rc : -1; } +######################################################################## +## Return command ID given the command name. +######################################################################## +sub get_command_id ($$) { + my ($dbh, $command_name) = @_; + + my $rc = get_db_value ($dbh, "SELECT id FROM talert_commands WHERE name = ?", safe_input($command_name)); + return defined ($rc) ? $rc : -1; +} + ######################################################################## ## Return agent ID given the agent name. ######################################################################## diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 0fe2d44eaf..4586d5cc86 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -162,6 +162,8 @@ sub help_screen{ help_screen_line('--enable_alerts', '', 'Enable alerts in all groups (system wide)'); help_screen_line('--create_alert_template', " \n\t [ \n\t \n\t \n\t ]", 'Create alert template'); help_screen_line('--delete_alert_template', '', 'Delete alert template'); + help_screen_line('--create_alert_command', " [ \n\t ", 'Create alert command'); + help_screen_line('--get_alert_commands', "[ \n\t ]", 'Displays all alert commands'); help_screen_line('--update_alert_template', " \n\t ", 'Update a field of an alert template'); help_screen_line('--validate_all_alerts', '', 'Validate all the alerts'); help_screen_line('--create_special_day', " ", 'Create special day'); @@ -3020,6 +3022,100 @@ sub cli_delete_alert_template() { exist_check($result,'alert template',$template_name); } +############################################################################## +# Add alert command. +# Related option: --create_alert_command +############################################################################## + +sub cli_create_alert_command() { + my ($command_name,$command,$group_name,$description,$internal,$fields_descriptions,$fields_values) = @ARGV[2..8]; + + print_log "[INFO] Adding command '$command_name'\n\n"; + + my $command_id = get_command_id($dbh,$command_name); + non_exist_check($command_id,'command',$command_name); + + my $id_group; + + if (! $group_name || $group_name eq "All") { + $id_group = 0; + } + else { + $id_group = get_group_id($dbh,$group_name); + exist_check($id_group,'group',$group_name); + } + + my %parameters; + + $parameters{'name'} = $command_name; + $parameters{'command'} = $command; + $parameters{'id_group'} = $id_group; + $parameters{'description'} = $description; + $parameters{'internal'} = $internal; + $parameters{'fields_descriptions'} = $fields_descriptions; + $parameters{'fields_values'} = $fields_values; + + pandora_create_alert_command ($conf, \%parameters, $dbh); +} + +############################################################################## +# Show all the alert commands (without parameters) or the alert commands with a filter parameters +# Related option: --get_alert_commands +############################################################################## + +sub cli_get_alert_commands() { + my ($command_name, $command, $group_name, $description, $internal) = @ARGV[2..6]; + + my $id_group; + my $condition = ' 1=1 '; + + if($command_name ne '') { + my $name = safe_input ($command_name); + $condition .= " AND name LIKE '%$name%' "; + } + + if($command ne '') { + $condition .= " AND command LIKE '%$command%' "; + } + + if($group_name ne '') { + $id_group = get_group_id($dbh, $group_name); + exist_check($id_group,'group',$group_name); + + $condition .= " AND id_grupo = $id_group "; + } + + if($description ne '') { + $condition .= " AND description LIKE '%$description%' "; + } + + if($internal ne '') { + $condition .= " AND internal = $internal "; + } + + my @alert_command = get_db_rows ($dbh, "SELECT * FROM talert_commands WHERE $condition"); + + if(scalar(@alert_command) == 0) { + print_log "[INFO] No commands found\n\n"; + exit; + } + + my $head_print = 0; + foreach my $commands (@alert_command) { + + if($head_print == 0) { + $head_print = 1; + print "id_command, command_name\n"; + } + print $commands->{'id'}.",".safe_output($commands->{'name'})."\n"; + } + + if($head_print == 0) { + print_log "[INFO] No commands found\n\n"; + } + +} + ############################################################################## # Add profile. # Related option: --add_profile @@ -5885,9 +5981,17 @@ sub pandora_manage_main ($$$) { cli_create_alert_template(); } elsif ($param eq '--delete_alert_template') { - param_check($ltotal, 1); + param_check($ltotal, 7); cli_delete_alert_template(); } + elsif ($param eq '--create_alert_command') { + param_check($ltotal, 7, 2); + cli_create_alert_command(); + } + elsif ($param eq '--get_alert_commands') { + param_check($ltotal, 5, 5); + cli_get_alert_commands(); + } elsif ($param eq '--update_alert_template') { param_check($ltotal, 3); cli_alert_template_update(); From e03b62d16818774b46b4239892a9273ebafe1e92 Mon Sep 17 00:00:00 2001 From: Daniel Maya Date: Mon, 28 Jan 2019 18:05:46 +0100 Subject: [PATCH 4/9] Fixed auto combined graph in metaconsole Former-commit-id: c0e819e35fbb5952fa8ce2806e9cddff521a5131 --- pandora_console/include/functions_reporting.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php index 6cc8683b4b..bd28f30f79 100755 --- a/pandora_console/include/functions_reporting.php +++ b/pandora_console/include/functions_reporting.php @@ -6397,7 +6397,7 @@ function reporting_custom_graph($report, $content, $type = 'dinamic', $graphs[0]["fullscale"] = $content['style']['fullscale']; $modules = $content['id_agent_module']; - if(!$modules){ + if(!$modules || !is_array($modules)) { $module_source = db_get_all_rows_sql( "SELECT id_agent_module, id_server FROM tgraph_source @@ -6405,7 +6405,7 @@ function reporting_custom_graph($report, $content, $type = 'dinamic', $content['id_gs'] ); - if(isset($module_source) && is_array($module_source)){ + if(isset($module_source) && is_array($module_source)) { $modules = array(); foreach ($module_source as $key => $value) { $modules[$key]['module'] = $value['id_agent_module']; From c05e99f37e7bc2ff6274aee5bc091fcc95ad87f2 Mon Sep 17 00:00:00 2001 From: Alejandro Fraguas Date: Tue, 29 Jan 2019 16:07:39 +0100 Subject: [PATCH 5/9] Update pandora_manage.pl Former-commit-id: 451b04e91078b99c8b9f41a35271797c343f357c --- pandora_server/util/pandora_manage.pl | 1 + 1 file changed, 1 insertion(+) diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index c55c6ce495..9cf6c244b8 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -6105,6 +6105,7 @@ sub pandora_manage_main ($$$) { elsif ($param eq '--get_alert_commands') { param_check($ltotal, 5, 5); cli_get_alert_commands(); + } elsif ($param eq '--get_alert_actions') { param_check($ltotal, 3, 3); cli_get_alert_actions(); From cc27f0451a26a180a344bc895fa9898bd5c3d906 Mon Sep 17 00:00:00 2001 From: Daniel Maya Date: Tue, 29 Jan 2019 17:12:24 +0100 Subject: [PATCH 6/9] Fixed auto combined graph in metaconsole 2 Former-commit-id: 672531931421175354f2a877ac295c1763107756 --- pandora_console/include/functions_reporting.php | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php index bd28f30f79..af9cab3702 100755 --- a/pandora_console/include/functions_reporting.php +++ b/pandora_console/include/functions_reporting.php @@ -6389,7 +6389,7 @@ function reporting_custom_graph($report, $content, $type = 'dinamic', $graphs = db_get_all_rows_field_filter ("tgraph", "id_graph", $content['id_gs']); $id_graph = $content['id_gs']; } - else if($type_report == "automatic_graph"){ + else if($type_report == "automatic_graph") { $graphs[0]["stacked"] = ''; $graphs[0]["summatory_series"] = ''; $graphs[0]["average_series"] = ''; @@ -6397,13 +6397,12 @@ function reporting_custom_graph($report, $content, $type = 'dinamic', $graphs[0]["fullscale"] = $content['style']['fullscale']; $modules = $content['id_agent_module']; - if(!$modules || !is_array($modules)) { + if (is_metaconsole()) { $module_source = db_get_all_rows_sql( - "SELECT id_agent_module, id_server - FROM tgraph_source - WHERE id_graph = " . - $content['id_gs'] - ); + "SELECT id_agent_module, id_server + FROM tgraph_source + WHERE id_graph = " . + $content['id_gs']); if(isset($module_source) && is_array($module_source)) { $modules = array(); From eb0b9bd05beec65165ea0f8f002ad0a243ddd135 Mon Sep 17 00:00:00 2001 From: Alejandro Fraguas Date: Tue, 29 Jan 2019 17:16:47 +0100 Subject: [PATCH 7/9] Update pandora_manage.pl Former-commit-id: 4064310d63eb101eb1a13825357aa5c425eae502 --- pandora_server/util/pandora_manage.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 9cf6c244b8..b7572da956 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -3175,7 +3175,9 @@ sub cli_get_alert_commands() { if($head_print == 0) { print_log "[INFO] No commands found\n\n"; } +} +############################################################################## # Get alert actions. # Related option: --get_alert_actions ############################################################################## From 3eeaf83ee331d1b25db6ffc4c2af907330c7cbac Mon Sep 17 00:00:00 2001 From: Samuel Carcases Date: Tue, 29 Jan 2019 17:40:25 +0100 Subject: [PATCH 8/9] Update pandora_manage.pl Former-commit-id: 4bc758a4284e96658137fb9580f36163a2031944 --- pandora_server/util/pandora_manage.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index b7572da956..4e88c09c6b 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -3144,7 +3144,7 @@ sub cli_get_alert_commands() { $id_group = get_group_id($dbh, $group_name); exist_check($id_group,'group',$group_name); - $condition .= " AND id_grupo = $id_group "; + $condition .= " AND id_group = $id_group "; } if($description ne '') { From 6485de04fd30f333f1cce509a9924d31f925695f Mon Sep 17 00:00:00 2001 From: artica Date: Wed, 30 Jan 2019 00:01:26 +0100 Subject: [PATCH 9/9] Auto-updated build strings. Former-commit-id: b5071a47e475e0aa13a62e9e76066cfd10d99ec1 --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 4 ++-- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 24 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index bd6022a72e..72abc0c503 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.731 +Version: 7.0NG.731-190130 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index 41596fb0a4..22a044bb54 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.731" +pandora_version="7.0NG.731-190130" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 0f3310dbe6..7c33041d65 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -42,7 +42,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.731'; -use constant AGENT_BUILD => '190129'; +use constant AGENT_BUILD => '190130'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 9afd3f7ba2..ebafb01118 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.731 -%define release 1 +%define release 190130 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index 2b96e28f21..e107a9b358 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.731 -%define release 1 +%define release 190130 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index 6235692d07..de175bdf2a 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.731" -PI_BUILD="190129" +PI_BUILD="190130" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 9537c6365b..faeb6db6bb 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{190129} +{190130} ViewReadme {Yes} @@ -2387,7 +2387,7 @@ Windows,BuildSeparateArchives {No} Windows,Executable -{<%AppName%>-Setup<%Ext%>} +{<%AppName%>-<%Version%>-Setup<%Ext%>} Windows,FileDescription {<%AppName%> <%Version%> Setup} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index 1b1209ea17..ee7b0f8011 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.731(Build 190129)") +#define PANDORA_VERSION ("7.0NG.731(Build 190130)") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index c63fac6c8c..025dd7eb33 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.731(Build 190129))" + VALUE "ProductVersion", "(7.0NG.731(Build 190130))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index 9b6db9ceae..4f975eec3e 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.731 +Version: 7.0NG.731-190130 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 4de8457efe..2075088e74 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.731" +pandora_version="7.0NG.731-190130" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 777c3b4e2c..96df7d128f 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -22,7 +22,7 @@ /** * Pandora build version and version */ -$build_version = 'PC190129'; +$build_version = 'PC190130'; $pandora_version = 'v7.0NG.731'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index dfd67f28f7..18a2a6d9cb 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -116,7 +116,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index 3f8b3fcda4..a56074565c 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.731 -%define release 1 +%define release 190130 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 6ed654d7c0..77565caae9 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.731 -%define release 1 +%define release 190130 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index baec459b7a..180aaba137 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.731" -PI_BUILD="190129" +PI_BUILD="190130" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index ab57e7cd08..076991b5ff 100644 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -34,7 +34,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.731 PS190129"; +my $version = "7.0NG.731 PS190130"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index bc4116736e..5043a1ca9a 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.731 PS190129"; +my $version = "7.0NG.731 PS190130"; # save program name for logging my $progname = basename($0);