mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 09:15:15 +02:00
Merge remote-tracking branch 'origin/develop' into ent-11471-integracion-pandora-integria
This commit is contained in:
commit
802f0bf83b
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-agent-unix
|
package: pandorafms-agent-unix
|
||||||
Version: 7.0NG.773.3-230911
|
Version: 7.0NG.773.3-230912
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# GNU General Public License for more details.
|
# GNU General Public License for more details.
|
||||||
|
|
||||||
pandora_version="7.0NG.773.3-230911"
|
pandora_version="7.0NG.773.3-230912"
|
||||||
|
|
||||||
echo "Test if you has the tools for to make the packages."
|
echo "Test if you has the tools for to make the packages."
|
||||||
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null
|
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null
|
||||||
|
@ -1031,7 +1031,7 @@ my $Sem = undef;
|
|||||||
my $ThreadSem = undef;
|
my $ThreadSem = undef;
|
||||||
|
|
||||||
use constant AGENT_VERSION => '7.0NG.773.3';
|
use constant AGENT_VERSION => '7.0NG.773.3';
|
||||||
use constant AGENT_BUILD => '230911';
|
use constant AGENT_BUILD => '230912';
|
||||||
|
|
||||||
# Agent log default file size maximum and instances
|
# Agent log default file size maximum and instances
|
||||||
use constant DEFAULT_MAX_LOG_SIZE => 600000;
|
use constant DEFAULT_MAX_LOG_SIZE => 600000;
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
%global __os_install_post %{nil}
|
%global __os_install_post %{nil}
|
||||||
%define name pandorafms_agent_linux
|
%define name pandorafms_agent_linux
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
Summary: Pandora FMS Linux agent, PERL version
|
Summary: Pandora FMS Linux agent, PERL version
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
%define name pandorafms_agent_linux_bin
|
%define name pandorafms_agent_linux_bin
|
||||||
%define source_name pandorafms_agent_linux
|
%define source_name pandorafms_agent_linux
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
Summary: Pandora FMS Linux agent, binary version
|
Summary: Pandora FMS Linux agent, binary version
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
%global __os_install_post %{nil}
|
%global __os_install_post %{nil}
|
||||||
%define name pandorafms_agent_linux
|
%define name pandorafms_agent_linux
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
Summary: Pandora FMS Linux agent, PERL version
|
Summary: Pandora FMS Linux agent, PERL version
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
# **********************************************************************
|
# **********************************************************************
|
||||||
|
|
||||||
PI_VERSION="7.0NG.773.3"
|
PI_VERSION="7.0NG.773.3"
|
||||||
PI_BUILD="230911"
|
PI_BUILD="230912"
|
||||||
OS_NAME=`uname -s`
|
OS_NAME=`uname -s`
|
||||||
|
|
||||||
FORCE=0
|
FORCE=0
|
||||||
|
@ -186,7 +186,7 @@ UpgradeApplicationID
|
|||||||
{}
|
{}
|
||||||
|
|
||||||
Version
|
Version
|
||||||
{230911}
|
{230912}
|
||||||
|
|
||||||
ViewReadme
|
ViewReadme
|
||||||
{Yes}
|
{Yes}
|
||||||
|
@ -30,7 +30,7 @@ using namespace Pandora;
|
|||||||
using namespace Pandora_Strutils;
|
using namespace Pandora_Strutils;
|
||||||
|
|
||||||
#define PATH_SIZE _MAX_PATH+1
|
#define PATH_SIZE _MAX_PATH+1
|
||||||
#define PANDORA_VERSION ("7.0NG.773.3 Build 230911")
|
#define PANDORA_VERSION ("7.0NG.773.3 Build 230912")
|
||||||
|
|
||||||
string pandora_path;
|
string pandora_path;
|
||||||
string pandora_dir;
|
string pandora_dir;
|
||||||
|
@ -11,7 +11,7 @@ BEGIN
|
|||||||
VALUE "LegalCopyright", "Pandora FMS"
|
VALUE "LegalCopyright", "Pandora FMS"
|
||||||
VALUE "OriginalFilename", "PandoraAgent.exe"
|
VALUE "OriginalFilename", "PandoraAgent.exe"
|
||||||
VALUE "ProductName", "Pandora FMS Windows Agent"
|
VALUE "ProductName", "Pandora FMS Windows Agent"
|
||||||
VALUE "ProductVersion", "(7.0NG.773.3(Build 230911))"
|
VALUE "ProductVersion", "(7.0NG.773.3(Build 230912))"
|
||||||
VALUE "FileVersion", "1.0.0.0"
|
VALUE "FileVersion", "1.0.0.0"
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-console
|
package: pandorafms-console
|
||||||
Version: 7.0NG.773.3-230911
|
Version: 7.0NG.773.3-230912
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# GNU General Public License for more details.
|
# GNU General Public License for more details.
|
||||||
|
|
||||||
pandora_version="7.0NG.773.3-230911"
|
pandora_version="7.0NG.773.3-230912"
|
||||||
|
|
||||||
package_pear=0
|
package_pear=0
|
||||||
package_pandora=1
|
package_pandora=1
|
||||||
|
@ -1025,6 +1025,27 @@ $table_font->data[$row][] = html_print_label_input_block(
|
|||||||
);
|
);
|
||||||
$row++;
|
$row++;
|
||||||
|
|
||||||
|
$table_font->data[$row][] = html_print_label_input_block(
|
||||||
|
__('Truncate agent text at end'),
|
||||||
|
html_print_checkbox_switch(
|
||||||
|
'truncate_agent_at_end',
|
||||||
|
1,
|
||||||
|
$config['truncate_agent_at_end'],
|
||||||
|
true
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
$table_font->data[$row][] = html_print_label_input_block(
|
||||||
|
__('Truncate module text at end'),
|
||||||
|
html_print_checkbox_switch(
|
||||||
|
'truncate_module_at_end',
|
||||||
|
1,
|
||||||
|
$config['truncate_module_at_end'],
|
||||||
|
true
|
||||||
|
)
|
||||||
|
);
|
||||||
|
$row++;
|
||||||
|
|
||||||
$table_font->data[$row][] = html_print_label_input_block(
|
$table_font->data[$row][] = html_print_label_input_block(
|
||||||
__('Agent size text'),
|
__('Agent size text'),
|
||||||
html_print_div(
|
html_print_div(
|
||||||
|
57
pandora_console/include/ajax/notifications.ajax.php
Normal file
57
pandora_console/include/ajax/notifications.ajax.php
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* Extension to manage a list of gateways and the node address where they should
|
||||||
|
* point to.
|
||||||
|
*
|
||||||
|
* @category Users
|
||||||
|
* @package Pandora FMS
|
||||||
|
* @subpackage Community
|
||||||
|
* @version 1.0.0
|
||||||
|
* @license See below
|
||||||
|
*
|
||||||
|
* ______ ___ _______ _______ ________
|
||||||
|
* | __ \.-----.--.--.--| |.-----.----.-----. | ___| | | __|
|
||||||
|
* | __/| _ | | _ || _ | _| _ | | ___| |__ |
|
||||||
|
* |___| |___._|__|__|_____||_____|__| |___._| |___| |__|_|__|_______|
|
||||||
|
*
|
||||||
|
* ============================================================================
|
||||||
|
* Copyright (c) 2005-2023 Pandora FMS
|
||||||
|
* Please see https://pandorafms.com/community/ for full contribution list
|
||||||
|
* 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 for version 2.
|
||||||
|
* 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.
|
||||||
|
* ============================================================================
|
||||||
|
*/
|
||||||
|
|
||||||
|
global $config;
|
||||||
|
|
||||||
|
// Includes.
|
||||||
|
require_once $config['homedir'].'/include/functions_notifications.php';
|
||||||
|
|
||||||
|
$change_label = get_parameter('change_label', 0);
|
||||||
|
if ($change_label === '1') {
|
||||||
|
$label = get_parameter('label', '');
|
||||||
|
$source = get_parameter('source', 0);
|
||||||
|
$user = get_parameter('user', '');
|
||||||
|
$value = get_parameter('value', 0) ? 1 : 0;
|
||||||
|
|
||||||
|
// Update the label value.
|
||||||
|
ob_clean();
|
||||||
|
$json = json_encode(
|
||||||
|
[
|
||||||
|
'result' => notifications_set_user_label_status(
|
||||||
|
$source,
|
||||||
|
$user,
|
||||||
|
$label,
|
||||||
|
$value
|
||||||
|
),
|
||||||
|
]
|
||||||
|
);
|
||||||
|
|
||||||
|
echo $json;
|
||||||
|
return;
|
||||||
|
}
|
@ -703,7 +703,7 @@ class ConsoleSupervisor
|
|||||||
$total_agents = db_get_value('count(*)', 'tagente');
|
$total_agents = db_get_value('count(*)', 'tagente');
|
||||||
|
|
||||||
if ($total_agents >= 200) {
|
if ($total_agents >= 200) {
|
||||||
if ($config['agentaccess'] !== 0) {
|
if ((int) $config['agentaccess'] !== 0) {
|
||||||
db_process_sql_update('tconfig', ['value' => 0], ['token' => 'agentaccess']);
|
db_process_sql_update('tconfig', ['value' => 0], ['token' => 'agentaccess']);
|
||||||
$this->notify(
|
$this->notify(
|
||||||
[
|
[
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
/**
|
/**
|
||||||
* Pandora build version and version
|
* Pandora build version and version
|
||||||
*/
|
*/
|
||||||
$build_version = 'PC230911';
|
$build_version = 'PC230912';
|
||||||
$pandora_version = 'v7.0NG.773.3';
|
$pandora_version = 'v7.0NG.773.3';
|
||||||
|
|
||||||
// Do not overwrite default timezone set if defined.
|
// Do not overwrite default timezone set if defined.
|
||||||
|
@ -1257,6 +1257,10 @@ function config_update_config()
|
|||||||
$error_update[] = __('Default line menu items for the Services');
|
$error_update[] = __('Default line menu items for the Services');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config_update_value('truncate_agent_at_end', get_parameter('truncate_agent_at_end'), true) === false) {
|
||||||
|
$error_update[] = __('Truncate agent text at end');
|
||||||
|
}
|
||||||
|
|
||||||
if (config_update_value('agent_size_text_small', get_parameter('agent_size_text_small'), true) === false) {
|
if (config_update_value('agent_size_text_small', get_parameter('agent_size_text_small'), true) === false) {
|
||||||
$error_update[] = __('Agent size text');
|
$error_update[] = __('Agent size text');
|
||||||
}
|
}
|
||||||
@ -1265,6 +1269,10 @@ function config_update_config()
|
|||||||
$error_update[] = __('Agent size text');
|
$error_update[] = __('Agent size text');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config_update_value('truncate_module_at_end', get_parameter('truncate_module_at_end'), true) === false) {
|
||||||
|
$error_update[] = __('Truncate module text at end');
|
||||||
|
}
|
||||||
|
|
||||||
if (config_update_value('module_size_text_small', get_parameter('module_size_text_small'), true) === false) {
|
if (config_update_value('module_size_text_small', get_parameter('module_size_text_small'), true) === false) {
|
||||||
$error_update[] = __('Module size text');
|
$error_update[] = __('Module size text');
|
||||||
}
|
}
|
||||||
@ -3509,6 +3517,10 @@ function config_process_config()
|
|||||||
config_update_value('display_item_frame', 1);
|
config_update_value('display_item_frame', 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!isset($config['truncate_agent_at_end'])) {
|
||||||
|
config_update_value('truncate_agent_at_end', 0);
|
||||||
|
}
|
||||||
|
|
||||||
if (!isset($config['agent_size_text_small'])) {
|
if (!isset($config['agent_size_text_small'])) {
|
||||||
config_update_value('agent_size_text_small', 18);
|
config_update_value('agent_size_text_small', 18);
|
||||||
}
|
}
|
||||||
@ -3517,6 +3529,10 @@ function config_process_config()
|
|||||||
config_update_value('agent_size_text_medium', 50);
|
config_update_value('agent_size_text_medium', 50);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!isset($config['truncate_module_at_end'])) {
|
||||||
|
config_update_value('truncate_module_at_end', 0);
|
||||||
|
}
|
||||||
|
|
||||||
if (!isset($config['module_size_text_small'])) {
|
if (!isset($config['module_size_text_small'])) {
|
||||||
config_update_value('module_size_text_small', 25);
|
config_update_value('module_size_text_small', 25);
|
||||||
}
|
}
|
||||||
|
@ -701,6 +701,7 @@ function modules_update_agent_module(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Disable action requires a special function
|
// Disable action requires a special function
|
||||||
|
$result = false;
|
||||||
if (isset($values['disabled'])) {
|
if (isset($values['disabled'])) {
|
||||||
$result_disable = modules_change_disabled($id, $values['disabled']);
|
$result_disable = modules_change_disabled($id, $values['disabled']);
|
||||||
|
|
||||||
@ -709,7 +710,9 @@ function modules_update_agent_module(
|
|||||||
$result_disable = true;
|
$result_disable = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = @db_process_sql_update('tagente_modulo', $values, $where);
|
if (empty($values) === false) {
|
||||||
|
$result = @db_process_sql_update('tagente_modulo', $values, $where);
|
||||||
|
}
|
||||||
|
|
||||||
if ($result == false) {
|
if ($result == false) {
|
||||||
if ($result_disable === ERR_GENERIC) {
|
if ($result_disable === ERR_GENERIC) {
|
||||||
|
@ -635,6 +635,12 @@ function notifications_get_user_label_status($source, $user, $label)
|
|||||||
array_keys(users_get_groups($user)),
|
array_keys(users_get_groups($user)),
|
||||||
array_keys(notifications_get_group_sources_for_select($source['id']))
|
array_keys(notifications_get_group_sources_for_select($source['id']))
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// Clean default common groups error for mesagges.
|
||||||
|
if ($common_groups[0] === 0) {
|
||||||
|
unset($common_groups[0]);
|
||||||
|
}
|
||||||
|
|
||||||
// No group found, return no permissions.
|
// No group found, return no permissions.
|
||||||
$value = empty($common_groups) ? false : $source[$label];
|
$value = empty($common_groups) ? false : $source[$label];
|
||||||
return notifications_build_user_enable_return($value, false);
|
return notifications_build_user_enable_return($value, false);
|
||||||
@ -760,9 +766,10 @@ function notifications_print_global_source_configuration($source)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Generate the title.
|
// Generate the title.
|
||||||
$html_title = "<div class='global-config-notification-title'>";
|
$html_title = '<h2 style="margin-bottom: auto;">'.$source['description'].'</h2>';
|
||||||
|
$html_title .= "<div class='global-config-notification-title'>";
|
||||||
$html_title .= html_print_switch($switch_values);
|
$html_title .= html_print_switch($switch_values);
|
||||||
$html_title .= '<h2>'.$source['description'].'</h2>';
|
$html_title .= '<h2>'.__('Enable user configuration').'</h2>';
|
||||||
$html_title .= '</div>';
|
$html_title .= '</div>';
|
||||||
|
|
||||||
// Generate the html for title.
|
// Generate the html for title.
|
||||||
|
@ -99,23 +99,27 @@ function ui_print_truncate_text(
|
|||||||
$forced_title=false
|
$forced_title=false
|
||||||
) {
|
) {
|
||||||
global $config;
|
global $config;
|
||||||
|
$truncate_at_end = false;
|
||||||
if (is_string($numChars)) {
|
if (is_string($numChars)) {
|
||||||
switch ($numChars) {
|
switch ($numChars) {
|
||||||
case 'agent_small':
|
case 'agent_small':
|
||||||
$numChars = $config['agent_size_text_small'];
|
$numChars = $config['agent_size_text_small'];
|
||||||
|
$truncate_at_end = (bool) $config['truncate_agent_at_end'];
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'agent_medium':
|
case 'agent_medium':
|
||||||
$numChars = $config['agent_size_text_medium'];
|
$numChars = $config['agent_size_text_medium'];
|
||||||
|
$truncate_at_end = (bool) $config['truncate_agent_at_end'];
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'module_small':
|
case 'module_small':
|
||||||
$numChars = $config['module_size_text_small'];
|
$numChars = $config['module_size_text_small'];
|
||||||
|
$truncate_at_end = (bool) $config['truncate_module_at_end'];
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'module_medium':
|
case 'module_medium':
|
||||||
$numChars = $config['module_size_text_medium'];
|
$numChars = $config['module_size_text_medium'];
|
||||||
|
$truncate_at_end = (bool) $config['truncate_module_at_end'];
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'description':
|
case 'description':
|
||||||
@ -147,27 +151,35 @@ function ui_print_truncate_text(
|
|||||||
// '/2' because [...] is in the middle of the word.
|
// '/2' because [...] is in the middle of the word.
|
||||||
$half_length = intval(($numChars - 3) / 2);
|
$half_length = intval(($numChars - 3) / 2);
|
||||||
|
|
||||||
// Depending on the strange behavior of mb_strimwidth() itself,
|
if ($truncate_at_end === true) {
|
||||||
// the 3rd parameter is not to be $numChars but the length of
|
// Recover the html entities to avoid XSS attacks.
|
||||||
// original text (just means 'large enough').
|
$truncateText = ($text_has_entities) ? io_safe_input(substr($text_html_decoded, 0, $numChars)) : substr($text_html_decoded, 0, $numChars);
|
||||||
$truncateText2 = mb_strimwidth(
|
if (strlen($text_html_decoded) > $numChars) {
|
||||||
$text_html_decoded,
|
$truncateText .= '...';
|
||||||
(mb_strlen($text_html_decoded, 'UTF-8') - $half_length),
|
}
|
||||||
mb_strlen($text_html_decoded, 'UTF-8'),
|
} else {
|
||||||
'',
|
// Depending on the strange behavior of mb_strimwidth() itself,
|
||||||
'UTF-8'
|
// the 3rd parameter is not to be $numChars but the length of
|
||||||
);
|
// original text (just means 'large enough').
|
||||||
|
$truncateText2 = mb_strimwidth(
|
||||||
|
$text_html_decoded,
|
||||||
|
(mb_strlen($text_html_decoded, 'UTF-8') - $half_length),
|
||||||
|
mb_strlen($text_html_decoded, 'UTF-8'),
|
||||||
|
'',
|
||||||
|
'UTF-8'
|
||||||
|
);
|
||||||
|
|
||||||
$truncateText = mb_strimwidth(
|
$truncateText = mb_strimwidth(
|
||||||
$text_html_decoded,
|
$text_html_decoded,
|
||||||
0,
|
0,
|
||||||
($numChars - $half_length),
|
($numChars - $half_length),
|
||||||
'',
|
'',
|
||||||
'UTF-8'
|
'UTF-8'
|
||||||
);
|
);
|
||||||
|
|
||||||
// Recover the html entities to avoid XSS attacks.
|
// Recover the html entities to avoid XSS attacks.
|
||||||
$truncateText = ($text_has_entities) ? io_safe_input($truncateText).$suffix.io_safe_input($truncateText2) : $truncateText.$suffix.$truncateText2;
|
$truncateText = ($text_has_entities) ? io_safe_input($truncateText).$suffix.io_safe_input($truncateText2) : $truncateText.$suffix.$truncateText2;
|
||||||
|
}
|
||||||
|
|
||||||
if ($showTextInTitle) {
|
if ($showTextInTitle) {
|
||||||
if ($style === null) {
|
if ($style === null) {
|
||||||
|
@ -131,7 +131,7 @@
|
|||||||
<div style='padding-bottom: 50px'>
|
<div style='padding-bottom: 50px'>
|
||||||
<?php
|
<?php
|
||||||
$version = '7.0NG.773.3';
|
$version = '7.0NG.773.3';
|
||||||
$build = '230911';
|
$build = '230912';
|
||||||
$banner = "v$version Build $build";
|
$banner = "v$version Build $build";
|
||||||
error_reporting(0);
|
error_reporting(0);
|
||||||
|
|
||||||
|
@ -523,19 +523,16 @@ if (is_ajax() === true) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (empty($tmp->module_name) === false) {
|
if (empty($tmp->module_name) === false) {
|
||||||
$tmp->module_name = io_safe_output($tmp->module_name);
|
$tmp->module_name = ui_print_truncate_text(
|
||||||
if (strlen($tmp->module_name) >= 20) {
|
$tmp->module_name,
|
||||||
$tmp->module_name = ui_print_truncate_text(
|
'module_medium',
|
||||||
$tmp->module_name,
|
false,
|
||||||
20,
|
true,
|
||||||
false,
|
false,
|
||||||
true,
|
'…',
|
||||||
false,
|
true,
|
||||||
'…',
|
true,
|
||||||
true,
|
);
|
||||||
true,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($tmp->comments) === false) {
|
if (empty($tmp->comments) === false) {
|
||||||
@ -564,19 +561,16 @@ if (is_ajax() === true) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$tmp->agent_name = io_safe_output($tmp->agent_name);
|
$tmp->agent_name = ui_print_truncate_text(
|
||||||
if (strlen($tmp->agent_name) >= 10) {
|
$tmp->agent_name,
|
||||||
$tmp->agent_name = ui_print_truncate_text(
|
'agent_small',
|
||||||
$tmp->agent_name,
|
false,
|
||||||
10,
|
true,
|
||||||
false,
|
false,
|
||||||
true,
|
'…',
|
||||||
false,
|
true,
|
||||||
'…',
|
true,
|
||||||
true,
|
);
|
||||||
true,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
$tmp->id_extra = io_safe_output($tmp->id_extra);
|
$tmp->id_extra = io_safe_output($tmp->id_extra);
|
||||||
if (strlen($tmp->id_extra) >= 10) {
|
if (strlen($tmp->id_extra) >= 10) {
|
||||||
@ -944,7 +938,8 @@ if (is_ajax() === true) {
|
|||||||
|
|
||||||
// Module name.
|
// Module name.
|
||||||
$tmp->id_agentmodule = $tmp->module_name;
|
$tmp->id_agentmodule = $tmp->module_name;
|
||||||
if (strlen($tmp->id_agentmodule) >= 10) {
|
/*
|
||||||
|
if (strlen($tmp->id_agentmodule) >= 10) {
|
||||||
$tmp->id_agentmodule = ui_print_truncate_text(
|
$tmp->id_agentmodule = ui_print_truncate_text(
|
||||||
$tmp->id_agentmodule,
|
$tmp->id_agentmodule,
|
||||||
10,
|
10,
|
||||||
@ -955,7 +950,7 @@ if (is_ajax() === true) {
|
|||||||
true,
|
true,
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
// Options.
|
// Options.
|
||||||
// Show more.
|
// Show more.
|
||||||
|
@ -216,7 +216,7 @@ if (check_acl_restricted_all($config['id_user'], $report_group, 'RW')) {
|
|||||||
$options['view'] = [
|
$options['view'] = [
|
||||||
'active' => true,
|
'active' => true,
|
||||||
'text' => '<a href="index.php?sec=reporting&sec2=operation/reporting/reporting_viewer&id='.$id_report.'&pure='.$pure.'">'.html_print_image(
|
'text' => '<a href="index.php?sec=reporting&sec2=operation/reporting/reporting_viewer&id='.$id_report.'&pure='.$pure.'">'.html_print_image(
|
||||||
'images/eye.png',
|
'images/see-details@svg.svg',
|
||||||
true,
|
true,
|
||||||
[
|
[
|
||||||
'title' => __('View report'),
|
'title' => __('View report'),
|
||||||
|
@ -15,6 +15,7 @@ global $config;
|
|||||||
|
|
||||||
enterprise_include_once('include/functions_policies.php');
|
enterprise_include_once('include/functions_policies.php');
|
||||||
require_once $config['homedir'].'/include/functions_users.php';
|
require_once $config['homedir'].'/include/functions_users.php';
|
||||||
|
require_once $config['homedir'].'/include/functions_reporting.php';
|
||||||
|
|
||||||
$searchAgents = get_parameter('search_agents', 0);
|
$searchAgents = get_parameter('search_agents', 0);
|
||||||
$stringSearchSQL = get_parameter('stringSearchSQL');
|
$stringSearchSQL = get_parameter('stringSearchSQL');
|
||||||
|
@ -36,33 +36,11 @@ require_once $config['homedir'].'/include/functions_notifications.php';
|
|||||||
$headerTitle = __('User notifications');
|
$headerTitle = __('User notifications');
|
||||||
require $config['homedir'].'/operation/users/user_edit_header.php';
|
require $config['homedir'].'/operation/users/user_edit_header.php';
|
||||||
|
|
||||||
if (get_parameter('change_label', 0)) {
|
|
||||||
$label = get_parameter('label', '');
|
|
||||||
$source = get_parameter('source', 0);
|
|
||||||
$user = get_parameter('user', '');
|
|
||||||
$value = get_parameter('value', 0) ? 1 : 0;
|
|
||||||
|
|
||||||
// Update the label value.
|
|
||||||
ob_clean();
|
|
||||||
echo json_encode(
|
|
||||||
[
|
|
||||||
'result' => notifications_set_user_label_status(
|
|
||||||
$source,
|
|
||||||
$user,
|
|
||||||
$label,
|
|
||||||
$value
|
|
||||||
),
|
|
||||||
]
|
|
||||||
);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
echo '<div id="user-notifications-wrapper" class="white_box table_div table_three_columns padding-2">
|
echo '<div id="user-notifications-wrapper" class="white_box table_div table_three_columns padding-2">
|
||||||
<div class="table_thead">
|
<div class="table_thead">
|
||||||
<div class="table_th"></div>
|
<div class="table_th"></div>
|
||||||
<div class="table_th">'.__('Enable').'</div>
|
<div class="table_th">'.__('Console notifications').'</div>
|
||||||
<div class="table_th">'.__('Also receive an email').'</div>
|
<div class="table_th">'.__('E-mail notifications').'</div>
|
||||||
</div>';
|
</div>';
|
||||||
|
|
||||||
$sources = notifications_get_all_sources();
|
$sources = notifications_get_all_sources();
|
||||||
@ -109,13 +87,12 @@ html_print_input_hidden('id_user', $id);
|
|||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
var check = document.getElementById(event.target.id);
|
var check = document.getElementById(event.target.id);
|
||||||
if (check === null) return;
|
if (check === null) return;
|
||||||
|
|
||||||
var match = /notifications-user-([0-9]+)-label-(.*)/
|
var match = /notifications-user-([0-9]+)-label-(.*)/
|
||||||
.exec(event.target.id);
|
.exec(event.target.id);
|
||||||
|
|
||||||
jQuery.post ("ajax.php",
|
jQuery.post ("ajax.php",
|
||||||
{
|
{
|
||||||
"page" : "operation/users/user_edit_notifications",
|
//"page" : "operation/users/user_edit_notifications",
|
||||||
|
"page" : 'include/ajax/notifications.ajax',
|
||||||
"change_label" : 1,
|
"change_label" : 1,
|
||||||
"label" : match[2],
|
"label" : match[2],
|
||||||
"source" : match[1],
|
"source" : match[1],
|
||||||
@ -148,4 +125,5 @@ html_print_input_hidden('id_user', $id);
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}());
|
}());
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
# User and Group under which Apache is running
|
# User and Group under which Apache is running
|
||||||
%define httpd_name httpd
|
%define httpd_name httpd
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
# User and Group under which Apache is running
|
# User and Group under which Apache is running
|
||||||
%define httpd_name httpd
|
%define httpd_name httpd
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
%define httpd_name httpd
|
%define httpd_name httpd
|
||||||
# User and Group under which Apache is running
|
# User and Group under which Apache is running
|
||||||
%define httpd_name apache2
|
%define httpd_name apache2
|
||||||
|
@ -16,7 +16,32 @@ if ($issues) {
|
|||||||
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
||||||
fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
|
fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
|
||||||
} elseif (!headers_sent()) {
|
} elseif (!headers_sent()) {
|
||||||
echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL;
|
require_once __DIR__.'/../../include/functions_ui.php';
|
||||||
|
|
||||||
|
$url = str_replace('/var/www/html/', '', __DIR__);
|
||||||
|
$url = str_replace('/vendor/composer', '', $url);
|
||||||
|
|
||||||
|
echo '<link rel="stylesheet" type="text/css" href="include/styles/pandora.css">';
|
||||||
|
?>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
body {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
|
||||||
|
echo '<div style="height:100%;min-height: 100%;display:flex;align-items:center;justify-content:center;background: linear-gradient(74deg, #02020255 36%, transparent 36%), url('.$url.'/../images/backgrounds/background_pandora_console_keys.jpg);">';
|
||||||
|
echo '<center><div align="middle" class="license_databox w600px pdd_10px" style="background-color: white;">';
|
||||||
|
echo '<img style="width: 600px" src="images/custom_logo/logo-default-pandorafms.png"><h2> Composer detected issues in your platform:</h2>';
|
||||||
|
echo '<div class="w90p height_100px" style="text-align:left;font-size: larger">';
|
||||||
|
echo sprintf(
|
||||||
|
'PandoraFMS requires PHP 8.0 to work properly and the version %s has been detected. Please update the PHP version of the system. More info %s. The latest version with PHP 7.4 support is PandoraFMS 767 hope LTS.',
|
||||||
|
PHP_VERSION,
|
||||||
|
'<a style="font-size: initial;" target="_blank" href="https://pandorafms.com/manual/en/documentation/07_technical_annexes/18_php_8">here</a>'
|
||||||
|
);
|
||||||
|
echo '</div></div></center></div>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
trigger_error(
|
trigger_error(
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-server
|
package: pandorafms-server
|
||||||
Version: 7.0NG.773.3-230911
|
Version: 7.0NG.773.3-230912
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
# GNU General Public License for more details.
|
# GNU General Public License for more details.
|
||||||
|
|
||||||
pandora_version="7.0NG.773.3-230911"
|
pandora_version="7.0NG.773.3-230912"
|
||||||
|
|
||||||
package_cpan=0
|
package_cpan=0
|
||||||
package_pandora=1
|
package_pandora=1
|
||||||
|
@ -46,7 +46,7 @@ our @EXPORT = qw(
|
|||||||
|
|
||||||
# version: Defines actual version of Pandora Server for this module only
|
# version: Defines actual version of Pandora Server for this module only
|
||||||
my $pandora_version = "7.0NG.773.3";
|
my $pandora_version = "7.0NG.773.3";
|
||||||
my $pandora_build = "230911";
|
my $pandora_build = "230912";
|
||||||
our $VERSION = $pandora_version." ".$pandora_build;
|
our $VERSION = $pandora_version." ".$pandora_build;
|
||||||
|
|
||||||
# Setup hash
|
# Setup hash
|
||||||
|
@ -34,7 +34,7 @@ our @ISA = qw(Exporter);
|
|||||||
|
|
||||||
# version: Defines actual version of Pandora Server for this module only
|
# version: Defines actual version of Pandora Server for this module only
|
||||||
my $pandora_version = "7.0NG.773.3";
|
my $pandora_version = "7.0NG.773.3";
|
||||||
my $pandora_build = "230911";
|
my $pandora_build = "230912";
|
||||||
our $VERSION = $pandora_version." ".$pandora_build;
|
our $VERSION = $pandora_version." ".$pandora_build;
|
||||||
|
|
||||||
our %EXPORT_TAGS = ( 'all' => [ qw() ] );
|
our %EXPORT_TAGS = ( 'all' => [ qw() ] );
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
%global __os_install_post %{nil}
|
%global __os_install_post %{nil}
|
||||||
%define name pandorafms_server
|
%define name pandorafms_server
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
Summary: Pandora FMS Server
|
Summary: Pandora FMS Server
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
%global __os_install_post %{nil}
|
%global __os_install_post %{nil}
|
||||||
%define name pandorafms_server
|
%define name pandorafms_server
|
||||||
%define version 7.0NG.773.3
|
%define version 7.0NG.773.3
|
||||||
%define release 230911
|
%define release 230912
|
||||||
|
|
||||||
Summary: Pandora FMS Server
|
Summary: Pandora FMS Server
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
# **********************************************************************
|
# **********************************************************************
|
||||||
|
|
||||||
PI_VERSION="7.0NG.773.3"
|
PI_VERSION="7.0NG.773.3"
|
||||||
PI_BUILD="230911"
|
PI_BUILD="230912"
|
||||||
|
|
||||||
MODE=$1
|
MODE=$1
|
||||||
if [ $# -gt 1 ]; then
|
if [ $# -gt 1 ]; then
|
||||||
|
@ -35,7 +35,7 @@ use PandoraFMS::Config;
|
|||||||
use PandoraFMS::DB;
|
use PandoraFMS::DB;
|
||||||
|
|
||||||
# version: define current version
|
# version: define current version
|
||||||
my $version = "7.0NG.773.3 Build 230911";
|
my $version = "7.0NG.773.3 Build 230912";
|
||||||
|
|
||||||
# Pandora server configuration
|
# Pandora server configuration
|
||||||
my %conf;
|
my %conf;
|
||||||
|
@ -36,7 +36,7 @@ use Encode::Locale;
|
|||||||
Encode::Locale::decode_argv;
|
Encode::Locale::decode_argv;
|
||||||
|
|
||||||
# version: define current version
|
# version: define current version
|
||||||
my $version = "7.0NG.773.3 Build 230911";
|
my $version = "7.0NG.773.3 Build 230912";
|
||||||
|
|
||||||
# save program name for logging
|
# save program name for logging
|
||||||
my $progname = basename($0);
|
my $progname = basename($0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user