Merge branch '1056-pandora-wux-grid-server' into 'develop'
1056 pandora wux grid server See merge request !773
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, AIX version
|
||||
# Version 7.0NG.710, AIX version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2010 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, FreeBSD Version
|
||||
# Version 7.0NG.710, FreeBSD Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2010 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, HP-UX Version
|
||||
# Version 7.0NG.710, HP-UX Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, GNU/Linux
|
||||
# Version 7.0NG.710, GNU/Linux
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, GNU/Linux
|
||||
# Version 7.0NG.710, GNU/Linux
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, Solaris Version
|
||||
# Version 7.0NG.710, Solaris Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Base config file for Pandora FMS Windows Agent
|
||||
# (c) 2006-2010 Artica Soluciones Tecnologicas
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
|
||||
# This program is Free Software, you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public Licence as published by the Free Software
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Fichero de configuracion base de agentes de Pandora
|
||||
# Base config file for Pandora agents
|
||||
# Version 7.0NG.711, AIX version
|
||||
# Version 7.0NG.710, AIX version
|
||||
|
||||
# General Parameters
|
||||
# ==================
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Fichero de configuracion base de agentes de Pandora
|
||||
# Base config file for Pandora agents
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
# FreeBSD/IPSO version
|
||||
# Licenced under GPL licence, 2003-2007 Sancho Lerena
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Fichero de configuracion base de agentes de Pandora
|
||||
# Base config file for Pandora agents
|
||||
# Version 7.0NG.711, HPUX Version
|
||||
# Version 7.0NG.710, HPUX Version
|
||||
|
||||
# General Parameters
|
||||
# ==================
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
# Licensed under GPL license v2,
|
||||
# (c) 2003-2010 Artica Soluciones Tecnologicas
|
||||
# please visit http://pandora.sourceforge.net
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
# Licensed under GPL license v2,
|
||||
# (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# please visit http://pandora.sourceforge.net
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
# Licensed under GPL license v2,
|
||||
# please visit http://pandora.sourceforge.net
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Fichero de configuracion base de agentes de Pandora
|
||||
# Base config file for Pandora agents
|
||||
# Version 7.0NG.711, Solaris version
|
||||
# Version 7.0NG.710, Solaris version
|
||||
|
||||
# General Parameters
|
||||
# ==================
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, AIX version
|
||||
# Version 7.0NG.710, AIX version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2010 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, GNU/Linux
|
||||
# Version 7.0NG.710, GNU/Linux
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2012 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, FreeBSD Version
|
||||
# Version 7.0NG.710, FreeBSD Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2016 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, HP-UX Version
|
||||
# Version 7.0NG.710, HP-UX Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, GNU/Linux
|
||||
# Version 7.0NG.710, GNU/Linux
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2014 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, GNU/Linux
|
||||
# Version 7.0NG.710, GNU/Linux
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, NetBSD Version
|
||||
# Version 7.0NG.710, NetBSD Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2010 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Base config file for Pandora FMS agents
|
||||
# Version 7.0NG.711, Solaris Version
|
||||
# Version 7.0NG.710, Solaris Version
|
||||
# Licensed under GPL license v2,
|
||||
# Copyright (c) 2003-2009 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Base config file for Pandora FMS Windows Agent
|
||||
# (c) 2006-2014 Artica Soluciones Tecnologicas
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
|
||||
# This program is Free Software, you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public Licence as published by the Free Software
|
||||
|
@ -167,7 +167,6 @@ function mainInsertData() {
|
||||
$params['use_hidden_input_idagent'] = true;
|
||||
$params['print_hidden_input_idagent'] = true;
|
||||
$params['hidden_input_idagent_id'] = 'hidden-autocomplete_id_agent';
|
||||
$params['hidden_input_idagent_value'] = $id_agente;
|
||||
|
||||
$table->data[0][1] = ui_print_agent_autocomplete_input($params);
|
||||
|
||||
|
@ -14,4 +14,8 @@ ALTER TABLE tserver ADD COLUMN exec_proxy tinyint(1) UNSIGNED NOT NULL default 0
|
||||
|
||||
ALTER TABLE tevent_response ADD COLUMN server_to_exec int(10) unsigned NOT NULL DEFAULT 0;
|
||||
|
||||
INSERT INTO tmodule VALUES (8, 'Wux module');
|
||||
|
||||
INSERT INTO ttipo_modulo VALUES (25,'web_analysis', 8, 'Web analysis data', 'module-wux.png');
|
||||
|
||||
COMMIT;
|
@ -1426,3 +1426,16 @@ ALTER TABLE tserver ADD COLUMN exec_proxy tinyint(1) UNSIGNED NOT NULL default 0
|
||||
-- Table `tevent_response`
|
||||
-- ---------------------------------------------------------------------
|
||||
ALTER TABLE tevent_response ADD COLUMN server_to_exec int(10) unsigned NOT NULL DEFAULT 0;
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `tmodule`
|
||||
-- ---------------------------------------------------------------------
|
||||
|
||||
INSERT INTO tmodule VALUES (8, 'Wux module');
|
||||
|
||||
-- ---------------------------------------------------------------------
|
||||
-- Table `ttipo_modulo`
|
||||
-- ---------------------------------------------------------------------
|
||||
|
||||
INSERT INTO ttipo_modulo VALUES (25,'web_analysis', 8, 'Web analysis data', 'module-wux.png');
|
||||
|
||||
|
@ -170,22 +170,18 @@ echo '<div class="login_page">';
|
||||
}
|
||||
else {
|
||||
echo '<div class="login_nick">';
|
||||
echo '<div style="width:15%;">';
|
||||
html_print_image ("/images/usuario_login.png", false);
|
||||
echo '</div>';
|
||||
echo '<div style="width:85%;">';
|
||||
html_print_input_text_extended ("nick", '', "nick", '', '', '' , false,
|
||||
'', 'autocomplete="off" placeholder="'.__('User').'"');
|
||||
echo '</div>';
|
||||
echo '<div>';
|
||||
html_print_image ("/images/usuario_login.png", false);
|
||||
echo '</div>';
|
||||
html_print_input_text_extended ("nick", '', "nick", '', '', '' , false,
|
||||
'', 'autocomplete="off" placeholder="'.__('User').'"');
|
||||
echo '</div>';
|
||||
echo '<div class="login_pass">';
|
||||
echo '<div style="width:15%;">';
|
||||
html_print_image ("/images/candado_login.png", false);
|
||||
echo '</div>';
|
||||
echo '<div style="width:85%;">';
|
||||
html_print_input_text_extended ("pass", '', "pass", '', '', '' ,false,
|
||||
'', 'autocomplete="off" placeholder="'.__('Password').'"', false, true);
|
||||
echo '</div>';
|
||||
echo '<div>';
|
||||
html_print_image ("/images/candado_login.png", false);
|
||||
echo '</div>';
|
||||
html_print_input_text_extended ("pass", '', "pass", '', '', '' ,false,
|
||||
'', 'autocomplete="off" placeholder="'.__('Password').'"', false, true);
|
||||
echo '</div>';
|
||||
echo '<div class="login_button">';
|
||||
html_print_submit_button(__("Login"), "login_button", false, 'class="sub next_login"');
|
||||
|
@ -541,7 +541,11 @@ if ($id_agente) {
|
||||
$help_header = 'plugins_tab';
|
||||
break;
|
||||
case "module":
|
||||
$type_module_t = (int) get_parameter ('moduletype', '');
|
||||
$tab_description = '- '. __('Modules');
|
||||
if($type_module_t == 'webux'){
|
||||
$help_header = 'wux_console';
|
||||
}
|
||||
break;
|
||||
case "alert":
|
||||
$tab_description = '- ' . __('Alert');
|
||||
@ -789,7 +793,7 @@ if ($update_agent) { // if modified some agent paramenter
|
||||
WHERE id_group = ".$group_old);
|
||||
|
||||
$result = db_process_sql_update ('tagente', $values, array ('id_agente' => $id_agente));
|
||||
if ($result == false) {
|
||||
if ($result === false) {
|
||||
ui_print_error_message(
|
||||
__('There was a problem updating the agent'));
|
||||
}
|
||||
@ -972,10 +976,18 @@ if ($update_module || $create_module) {
|
||||
$custom_integer_1_default = $module['custom_integer_1'];
|
||||
$custom_integer_2_default = $module['custom_integer_2'];
|
||||
}
|
||||
$custom_string_1 = (string) get_parameter ('custom_string_1', $custom_string_1_default);
|
||||
|
||||
if($id_module_type == 25){ # web analysis, from MODULE_WUX
|
||||
$custom_string_1 = base64_encode((string) get_parameter ('custom_string_1', $custom_string_1_default));
|
||||
$custom_integer_1 = (int) get_parameter ('custom_integer_1', $custom_integer_1_default);
|
||||
}
|
||||
else{
|
||||
$custom_string_1 = (string) get_parameter ('custom_string_1', $custom_string_1_default);
|
||||
$custom_integer_1 = (int) get_parameter ('prediction_module', $custom_integer_1_default);
|
||||
}
|
||||
|
||||
$custom_string_2 = (string) get_parameter ('custom_string_2', $custom_string_2_default);
|
||||
$custom_string_3 = (string) get_parameter ('custom_string_3', $custom_string_3_default);
|
||||
$custom_integer_1 = (int) get_parameter ('prediction_module', $custom_integer_1_default);
|
||||
$custom_integer_2 = (int) get_parameter ('custom_integer_2', $custom_integer_2_default);
|
||||
|
||||
// Get macros
|
||||
|
@ -180,7 +180,8 @@ echo "</tr></table>";
|
||||
$order_collation = "";
|
||||
switch ($config["dbtype"]) {
|
||||
case "mysql":
|
||||
$order_collation = "COLLATE utf8_general_ci";
|
||||
$order_collation = "";
|
||||
//$order_collation = "COLLATE utf8_general_ci";
|
||||
break;
|
||||
case "postgresql":
|
||||
case "oracle":
|
||||
@ -274,7 +275,6 @@ switch ($sortField) {
|
||||
}
|
||||
|
||||
$search_sql = '';
|
||||
|
||||
if ($search != "") {
|
||||
$sql = "SELECT DISTINCT taddress_agent.id_agent FROM taddress
|
||||
INNER JOIN taddress_agent ON
|
||||
|
@ -98,6 +98,9 @@ if (strstr($sec2, "enterprise/godmode/policies/policies") !== false) {
|
||||
//the modules to show in syntetic module policy form must be the policy
|
||||
//modules from the same policy.
|
||||
unset($modules['predictionserver']);
|
||||
if (enterprise_installed()){
|
||||
unset($modules['webux']);
|
||||
}
|
||||
}
|
||||
|
||||
$show_creation = false;
|
||||
@ -738,10 +741,15 @@ foreach ($modules as $module) {
|
||||
$data[6] = ui_print_status_image($status, $title, true);
|
||||
|
||||
// MAX / MIN values
|
||||
$data[7] = ui_print_module_warn_value ($module["max_warning"],
|
||||
$module["min_warning"], $module["str_warning"],
|
||||
$module["max_critical"], $module["min_critical"],
|
||||
$module["str_critical"]);
|
||||
if($module['id_tipo_modulo'] != 25){
|
||||
$data[7] = ui_print_module_warn_value ($module["max_warning"],
|
||||
$module["min_warning"], $module["str_warning"],
|
||||
$module["max_critical"], $module["min_critical"],
|
||||
$module["str_critical"]);
|
||||
}
|
||||
else{
|
||||
$data[7] = "";
|
||||
}
|
||||
|
||||
if ($module['disabled']) {
|
||||
$data[8] = "<a href='index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente=".$id_agente."&enable_module=".$module['id_agente_modulo']."'>".
|
||||
@ -753,8 +761,8 @@ foreach ($modules as $module) {
|
||||
html_print_image('images/lightbulb.png', true,
|
||||
array('alt' => __('Disable module'), 'title' => __('Disable module'))) ."</a>";
|
||||
}
|
||||
|
||||
if (check_acl ($config['id_user'], $agent['id_grupo'], "AW")) {
|
||||
|
||||
if (check_acl ($config['id_user'], $agent['id_grupo'], "AW") && $module['id_tipo_modulo'] != 25) {
|
||||
$data[8] .= ' <a href="index.php?sec=gagente&tab=module&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.'&duplicate_module='.$module['id_agente_modulo'].'"
|
||||
onClick="if (!confirm(\' ' . __('Are you sure?') . '\')) return false;">';
|
||||
$data[8] .= html_print_image ('images/copy.png', true,
|
||||
|
@ -183,7 +183,7 @@ if ($id_agent_module) {
|
||||
|
||||
// Security level Could be noAuthNoPriv | authNoPriv | authPriv
|
||||
$snmp3_security_level = $module["custom_string_3"];
|
||||
|
||||
|
||||
$ip_target = $module['ip_target'];
|
||||
$disabled = $module['disabled'];
|
||||
$id_export = $module['id_export'];
|
||||
@ -193,7 +193,10 @@ if ($id_agent_module) {
|
||||
$id_plugin = $module['id_plugin'];
|
||||
$post_process = $module['post_process'];
|
||||
$prediction_module = $module['prediction_module'];
|
||||
$custom_integer_1 = $module ['custom_integer_1'];
|
||||
$custom_integer_2 = $module ['custom_integer_2'];
|
||||
$custom_string_1 = $module ['custom_string_1'];
|
||||
$custom_string_2 = $module ['custom_string_2'];
|
||||
$max_timeout = $module['max_timeout'];
|
||||
$max_retries = $module['max_retries'];
|
||||
$custom_id = $module['custom_id'];
|
||||
@ -301,7 +304,10 @@ else {
|
||||
$quiet_module = 0;
|
||||
$unit = '';
|
||||
$prediction_module = '';
|
||||
$custom_integer_1 = 0;
|
||||
$custom_integer_2 = 0;
|
||||
$custom_string_1 = '';
|
||||
$custom_string_2 = '';
|
||||
$id_plugin = '';
|
||||
$id_export = '';
|
||||
$disabled = "0";
|
||||
@ -509,15 +515,18 @@ echo '<h3 id="message" class="error invisible"></h3>';
|
||||
|
||||
// TODO: Change to the ui_print_error system
|
||||
echo '<form method="post" id="module_form">';
|
||||
|
||||
html_print_table ($table_simple);
|
||||
|
||||
ui_toggle(html_print_table ($table_advanced, true),
|
||||
__('Advanced options'));
|
||||
ui_toggle(html_print_table ($table_macros, true),
|
||||
__('Custom macros') . ui_print_help_icon ('module_macros', true));
|
||||
ui_toggle(html_print_table ($table_new_relations, true) .
|
||||
html_print_table ($table_relations, true), __('Module relations'));
|
||||
|
||||
if($moduletype != 13){
|
||||
ui_toggle(html_print_table ($table_new_relations, true) .
|
||||
html_print_table ($table_relations, true), __('Module relations'));
|
||||
}
|
||||
|
||||
// Submit
|
||||
echo '<div class="action-buttons" style="width: '.$table_simple->width.'">';
|
||||
@ -567,10 +576,14 @@ var no_target_lang = "<?php echo __('No target IP provided') ?>";
|
||||
var no_oid_lang = "<?php echo __('No SNMP OID provided') ?>";
|
||||
var no_prediction_module_lang = "<?php echo __('No module to predict') ?>";
|
||||
var no_plugin_lang = "<?php echo __('No plug-in provided') ?>";
|
||||
var no_execute_test_from = "<?php echo __('No server provided') ?>"
|
||||
|
||||
$(document).ready (function () {
|
||||
configure_modules_form ();
|
||||
|
||||
|
||||
|
||||
|
||||
$("#module_form").submit(function() {
|
||||
if (typeof(check_remote_conf) != 'undefined') {
|
||||
if (check_remote_conf) {
|
||||
@ -619,6 +632,46 @@ $(document).ready (function () {
|
||||
$("#id_module_type").change (function () {
|
||||
checkKeepaliveModule();
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function handleFileSelect() {
|
||||
//clear texarea
|
||||
$('#textarea_custom_string_1').empty();
|
||||
$('#mssg_error_div').empty();
|
||||
|
||||
//messages error
|
||||
err_msg_1 = "<?php echo __('The File APIs are not fully supported in this browser.'); ?>";
|
||||
err_msg_2 = "<?php echo __('Couldn`t find the fileinput element.'); ?>";
|
||||
err_msg_3 = "<?php echo __('This browser doesn`t seem to support the files property of file inputs.'); ?>";
|
||||
err_msg_4 = "<?php echo __('Please select a file before clicking Load'); ?>";
|
||||
|
||||
if (!window.File || !window.FileReader || !window.FileList || !window.Blob) {
|
||||
$('#mssg_error_div').append(err_msg_1);
|
||||
return;
|
||||
}
|
||||
|
||||
input = document.getElementById('file-file_html_text');
|
||||
|
||||
if (!input) {
|
||||
$('#mssg_error_div').append(err_msg_2);
|
||||
}
|
||||
else if (!input.files) {
|
||||
$('#mssg_error_div').append(err_msg_3);
|
||||
}
|
||||
else if (!input.files[0]) {
|
||||
$('#mssg_error_div').append(err_msg_4);
|
||||
}
|
||||
else {
|
||||
file = input.files[0];
|
||||
fr = new FileReader();
|
||||
fr.onload = receivedText;
|
||||
fr.readAsText(file);
|
||||
}
|
||||
}
|
||||
|
||||
function receivedText() {
|
||||
document.getElementById('textarea_custom_string_1').appendChild(document.createTextNode(fr.result));
|
||||
}
|
||||
/* ]]> */
|
||||
</script>
|
||||
|
@ -978,32 +978,6 @@ function advanced_option_dynamic() {
|
||||
}
|
||||
}
|
||||
|
||||
//Add a new module macro
|
||||
function add_macro () {
|
||||
var macro_count = parseInt($("#hidden-module_macro_count").val());
|
||||
var delete_icon = '<?php html_print_image ("images/cross.png", false) ?>';
|
||||
|
||||
// Add inputs for the new macro
|
||||
$("#module_macros").append('<tr id="module_macros-' + macro_count + '" class="datos2"><td style=" font-weight: bold; vertical-align: top;" class="datos2">Name</td> \
|
||||
<td style="" class="datos2"><input type="text" name="module_macro_names[]" value="" id="text-module_macro_names[]" size="50" maxlength="60"></td> \
|
||||
<td style="font-weight: bold; vertical-align: top;" class="datos2">Value</td> \
|
||||
<td style="" class="datos2"><input type="text" name="module_macro_values[]" value="" id="text-module_macro_values[]" size="50" maxlength="60"></td> \
|
||||
<td style="" class="datos2"><a href="javascript: delete_macro(' + macro_count + ');">' + delete_icon + '</a></td></tr>');
|
||||
|
||||
// Update the macro count
|
||||
$("#hidden-module_macro_count").val(macro_count + 1);
|
||||
}
|
||||
|
||||
// Delete an existing module macro
|
||||
function delete_macro (num) {
|
||||
if ($("#module_macros-" + num).length) {
|
||||
$("#module_macros-" + num).remove();
|
||||
}
|
||||
|
||||
// Do not decrease the macro counter or new macros may overlap existing ones!
|
||||
}
|
||||
|
||||
|
||||
/* Relationship javascript */
|
||||
|
||||
// Change the modules autocomplete input depending on the result of the agents autocomplete input
|
||||
|
@ -149,6 +149,7 @@ $table->data = array();
|
||||
|
||||
$fields_available = array();
|
||||
|
||||
$fields_available['id_evento'] = __('Event id');
|
||||
$fields_available['evento'] = __('Event name');
|
||||
$fields_available['id_agente'] = __('Agent name');
|
||||
$fields_available['id_usuario'] = __('User');
|
||||
|
@ -539,7 +539,7 @@ switch ($action) {
|
||||
$table->size[3] = '2%';
|
||||
$table->size[4] = '2%';
|
||||
$table->size[5] = '2%';
|
||||
$table->size[6] = '4%';
|
||||
$table->size[6] = '2%';
|
||||
$table->size['csv'] = '5%';
|
||||
|
||||
$next = 4;
|
||||
|
@ -127,7 +127,7 @@ else {
|
||||
|
||||
$disable_user = get_parameter ("disable_user", false);
|
||||
|
||||
if (isset ($_GET["user_del"]) && isset ($_GET["delete_user"])) { //delete user
|
||||
if (isset ($_GET["user_del"])) { //delete user
|
||||
$id_user = get_parameter ("delete_user", 0);
|
||||
// Only allow delete user if is not the actual user
|
||||
if ($id_user != $config['id_user']) {
|
||||
@ -197,17 +197,16 @@ elseif ($disable_user !== false) { //disable_user
|
||||
else {
|
||||
$result = false;
|
||||
}
|
||||
if($result != null){
|
||||
if ($disable_user == 1) {
|
||||
ui_print_result_message ($result,
|
||||
__('Successfully disabled'),
|
||||
__('There was a problem disabling user'));
|
||||
}
|
||||
else {
|
||||
ui_print_result_message ($result,
|
||||
__('Successfully enabled'),
|
||||
__('There was a problem enabling user'));
|
||||
}
|
||||
|
||||
if ($disable_user == 1) {
|
||||
ui_print_result_message ($result,
|
||||
__('Successfully disabled'),
|
||||
__('There was a problem disabling user'));
|
||||
}
|
||||
else {
|
||||
ui_print_result_message ($result,
|
||||
__('Successfully enabled'),
|
||||
__('There was a problem enabling user'));
|
||||
}
|
||||
}
|
||||
|
||||
|
BIN
pandora_console/images/error_1.png
Normal file
After ![]() (image error) Size: 2.2 KiB |
BIN
pandora_console/images/exito.png
Normal file
After ![]() (image error) Size: 2.3 KiB |
BIN
pandora_console/images/help/Ux10.JPG
Normal file
After (image error) Size: 51 KiB |
BIN
pandora_console/images/help/Ux11.JPG
Normal file
After (image error) Size: 8.1 KiB |
BIN
pandora_console/images/help/Ux13.JPG
Normal file
After (image error) Size: 52 KiB |
BIN
pandora_console/images/help/Ux14.JPG
Normal file
After (image error) Size: 48 KiB |
BIN
pandora_console/images/help/Ux15.JPG
Normal file
After (image error) Size: 72 KiB |
BIN
pandora_console/images/help/Ux16.JPG
Normal file
After (image error) Size: 31 KiB |
BIN
pandora_console/images/help/Ux6.JPG
Normal file
After (image error) Size: 84 KiB |
BIN
pandora_console/images/help/Ux7.JPG
Normal file
After (image error) Size: 32 KiB |
BIN
pandora_console/images/help/Ux9.JPG
Normal file
After (image error) Size: 94 KiB |
BIN
pandora_console/images/help/WUX_v1.png
Normal file
After ![]() (image error) Size: 86 KiB |
BIN
pandora_console/images/help/WUX_v2.png
Normal file
After ![]() (image error) Size: 60 KiB |
BIN
pandora_console/images/help/WUX_v3.png
Normal file
After ![]() (image error) Size: 69 KiB |
BIN
pandora_console/images/icono-wux.png
Normal file
After ![]() (image error) Size: 503 B |
BIN
pandora_console/images/module-wux.png
Normal file
After ![]() (image error) Size: 500 B |
BIN
pandora_console/images/reloj.png
Normal file
After ![]() (image error) Size: 2.3 KiB |
BIN
pandora_console/images/search_big.png
Normal file
After ![]() (image error) Size: 2.2 KiB |
BIN
pandora_console/images/unknown.png
Normal file
After ![]() (image error) Size: 2.0 KiB |
BIN
pandora_console/images/wux.png
Normal file
After ![]() (image error) Size: 518 B |
@ -38,7 +38,9 @@ $get_agent_modules_json_by_name = (bool) get_parameter('get_agent_modules_json_b
|
||||
|
||||
|
||||
if ($get_agent_modules_json_by_name) {
|
||||
$agent_id = get_parameter('id_agent');
|
||||
$agent_name = get_parameter('agent_name');
|
||||
|
||||
$agent_id = agents_get_agent_id($agent_name);
|
||||
|
||||
$agent_modules = db_get_all_rows_sql("SELECT id_agente_modulo as id_module, nombre as name FROM tagente_modulo
|
||||
WHERE id_agente = " . $agent_id);
|
||||
@ -737,7 +739,7 @@ if ($list_modules) {
|
||||
$table->head[5] = __('Status') . ' ' .
|
||||
'<a href="' . $url . '&sort_field=status&sort=up&refr=&filter_monitors=1&status_filter_monitor=' .$status_filter_monitor.' &status_text_monitor='. $status_text_monitor.'&status_module_group= '.$status_module_group.'">' . html_print_image("images/sort_up.png", true, array("style" => $selectStatusUp, "alt" => "up")) . '</a>' .
|
||||
'<a href="' . $url . '&sort_field=status&sort=down&refr=&filter_monitors=1&status_filter_monitor=' .$status_filter_monitor.' &status_text_monitor='. $status_text_monitor.'&status_module_group= '.$status_module_group.'">' . html_print_image("images/sort_down.png", true, array("style" => $selectStatusDown, "alt" => "down")) . '</a>';
|
||||
$table->head[6] = __('Thresholds');
|
||||
$table->head[6] = __('Warn');
|
||||
$table->head[7] = __('Data');
|
||||
$table->head[8] = __('Graph');
|
||||
$table->head[9] = __('Last contact') . ' ' .
|
||||
@ -1010,8 +1012,12 @@ if ($list_modules) {
|
||||
$module["current_interval"], $module["module_name"]);
|
||||
}
|
||||
}
|
||||
|
||||
if($module["id_tipo_modulo"] != 25){
|
||||
$data[6] = ui_print_module_warn_value ($module["max_warning"], $module["min_warning"], $module["str_warning"], $module["max_critical"], $module["min_critical"], $module["str_critical"]);
|
||||
}
|
||||
else{
|
||||
$data[6] = "";
|
||||
}
|
||||
|
||||
$data[7] = $salida;
|
||||
$graph_type = return_graphtype ($module["id_tipo_modulo"]);
|
||||
|
@ -645,26 +645,15 @@ function ldap_process_user_login ($login, $password) {
|
||||
}
|
||||
}
|
||||
|
||||
$ldap_login_attr = !empty($config["ldap_login_attr"]) ? io_safe_output($config["ldap_login_attr"]) . "=" : '';
|
||||
$ldap_base_dn = !empty($config["ldap_base_dn"]) ? "," . io_safe_output($config["ldap_base_dn"]) : '';
|
||||
$ldap_login_attr = isset($config["ldap_login_attr"]) ? io_safe_output($config["ldap_login_attr"]) . "=" : '';
|
||||
$ldap_base_dn = isset($config["ldap_base_dn"]) ? "," . io_safe_output($config["ldap_base_dn"]) : '';
|
||||
|
||||
if(!empty($ldap_base_dn)){
|
||||
if (strlen($password) == 0 ||
|
||||
!@ldap_bind($ds, $ldap_login_attr.io_safe_output($login).$ldap_base_dn, $password) ) {
|
||||
html_debug("entra1",true);
|
||||
$config["auth_error"] = 'User not found in database or incorrect password';
|
||||
@ldap_close ($ds);
|
||||
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
if (strlen($password) == 0 ||
|
||||
if (strlen($password) == 0 ||
|
||||
!@ldap_bind($ds, io_safe_output($login), $password) ) {
|
||||
$config["auth_error"] = 'User not found in database or incorrect password';
|
||||
@ldap_close ($ds);
|
||||
|
||||
return false;
|
||||
}
|
||||
$config["auth_error"] = 'User not found in database or incorrect password';
|
||||
@ldap_close ($ds);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@ldap_close ($ds);
|
||||
|
@ -311,6 +311,7 @@ define ('MODULE_PLUGIN', 4);
|
||||
define ('MODULE_PREDICTION', 5);
|
||||
define ('MODULE_WMI', 6);
|
||||
define ('MODULE_WEB', 7);
|
||||
define ('MODULE_WUX', 8);
|
||||
|
||||
/* Type of Modules of Prediction */
|
||||
define ('MODULE_PREDICTION_SERVICE', 2);
|
||||
@ -351,6 +352,7 @@ define('SERVER_TYPE_ENTERPRISE_SATELLITE', 13);
|
||||
define('SERVER_TYPE_ENTERPRISE_TRANSACTIONAL', 14);
|
||||
define('SERVER_TYPE_MAINFRAME', 15);
|
||||
define('SERVER_TYPE_SYNC', 16);
|
||||
define('SERVER_TYPE_WUX', 17);
|
||||
|
||||
/* REPORTS */
|
||||
define('REPORT_TOP_N_MAX', 1);
|
||||
|
@ -1712,7 +1712,7 @@ function check_sql ($sql) {
|
||||
|
||||
//Check that it not delete_ as "delete_pending" (this is a common field in pandora tables).
|
||||
|
||||
if (preg_match("/\*|delete[^_]|drop|alter|modify|password|pass|insert|update/i", $sql)) {
|
||||
if (preg_match("/\*|delete[^_]|drop|alter|modify|union|password|pass|insert|update/i", $sql)) {
|
||||
return "";
|
||||
}
|
||||
return $sql;
|
||||
|
@ -9112,9 +9112,8 @@ function api_set_create_event($id, $trash1, $other, $returnType) {
|
||||
* http://127.0.0.1/pandora_console/include/api.php?op=set&op2=add_event_comment&id=event_id&other=string|&other_mode=url_encode_separator_|&apipass=1234&user=admin&pass=pandora
|
||||
*/
|
||||
function api_set_add_event_comment($id, $thrash2, $other, $thrash3) {
|
||||
$meta = false;
|
||||
if (defined ('METACONSOLE')) {
|
||||
$meta = true;
|
||||
return;
|
||||
}
|
||||
|
||||
if ($other['type'] == 'string') {
|
||||
@ -9123,9 +9122,11 @@ function api_set_add_event_comment($id, $thrash2, $other, $thrash3) {
|
||||
}
|
||||
else if ($other['type'] == 'array') {
|
||||
$comment = io_safe_input($other['data'][0]);
|
||||
$meta = $other['data'][1];
|
||||
$history = $other['data'][2];
|
||||
|
||||
$status = events_comment($id, $comment, 'Added comment', $meta, $history);
|
||||
$status = events_comment($id, $comment, 'Added comment', $meta,
|
||||
$history);
|
||||
if (is_error($status)) {
|
||||
returnError('error_add_event_comment',
|
||||
__('Error adding event comment.'));
|
||||
@ -9940,14 +9941,7 @@ function api_get_module_graph($id_module, $thrash2, $other, $thrash4) {
|
||||
$other['data'][0]
|
||||
:
|
||||
SECONDS_1HOUR; // 1 hour by default
|
||||
|
||||
$graph_threshold =
|
||||
(!empty($other) && isset($other['data'][2]))
|
||||
?
|
||||
$other['data'][2]
|
||||
:
|
||||
0;
|
||||
|
||||
|
||||
if (is_nan($graph_seconds) || $graph_seconds <= 0) {
|
||||
// returnError('error_module_graph', __(''));
|
||||
return;
|
||||
@ -9958,44 +9952,41 @@ function api_get_module_graph($id_module, $thrash2, $other, $thrash4) {
|
||||
$id_module, $graph_seconds, false, 600, 300, '',
|
||||
'', false, false, true, time(), '', 0, 0, true, true,
|
||||
ui_get_full_url(false) . '/', 1, false, '', false, true,
|
||||
true, 'white', null, false, false, $config['type_module_charts'],
|
||||
false, false);
|
||||
true, 'white', null, false, false, $config['type_module_charts']);
|
||||
|
||||
$graph_image_file_encoded = false;
|
||||
$graph_image_file_encoded = false;
|
||||
if (preg_match("/<img src='(.+)'./", $graph_html, $matches)) {
|
||||
$file_url = $matches[1];
|
||||
|
||||
if (preg_match("/\?(.+)&(.+)&(.+)&(.+)/", $file_url,$parameters)) {
|
||||
array_shift ($parameters);
|
||||
foreach ($parameters as $parameter){
|
||||
$value = explode ("=",$parameter);
|
||||
if (preg_match("/\?(.+)&(.+)&(.+)&(.+)/", $file_url,$parameters)) {
|
||||
array_shift ($parameters);
|
||||
foreach ($parameters as $parameter){
|
||||
$value = explode ("=",$parameter);
|
||||
|
||||
if (strcmp($value[0], "static_graph") == 0){
|
||||
$static_graph = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "graph_type") == 0){
|
||||
$graph_type = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "ttl") == 0){
|
||||
$ttl = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "id_graph") == 0){
|
||||
$id_graph = $value[1];
|
||||
}
|
||||
if (strcmp($value[0], "static_graph") == 0){
|
||||
$static_graph = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "graph_type") == 0){
|
||||
$graph_type = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "ttl") == 0){
|
||||
$ttl = $value[1];
|
||||
}
|
||||
elseif (strcmp($value[0], "id_graph") == 0){
|
||||
$id_graph = $value[1];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Check values are OK
|
||||
if ( (isset ($graph_type))
|
||||
&& (isset ($ttl))
|
||||
&& (isset ($id_graph))) {
|
||||
$_GET["ttl"] = $ttl;
|
||||
$_GET["id_graph"] = $id_graph;
|
||||
$_GET["graph_type"] = $graph_type;
|
||||
$_GET["static_graph"] = $static_graph;
|
||||
$_GET["graph_threshold"] = $graph_threshold;
|
||||
$_GET["id_module"] = $id_module;
|
||||
$_GET["ttl"] = $ttl;
|
||||
$_GET["id_graph"] = $id_graph;
|
||||
$_GET["graph_type"] = $graph_type;
|
||||
$_GET["static_graph"] = $static_graph;
|
||||
}
|
||||
|
||||
ob_start();
|
||||
|
@ -3222,11 +3222,11 @@ function grafico_eventos_grupo ($width = 300, $height = 200, $url = "", $meta =
|
||||
}
|
||||
else {
|
||||
if ($meta) {
|
||||
$name = mb_substr (io_safe_output($row['agent_name']), 0, 25)." (".$row["count"].")";
|
||||
$name = mb_substr (io_safe_output($row['agent_name']), 0, 14)." (".$row["count"].")";
|
||||
}
|
||||
else {
|
||||
$alias = agents_get_alias($row["id_agente"]);
|
||||
$name = mb_substr($alias, 0, 25)." #".$row["id_agente"]." (".$row["count"].")";
|
||||
$name = mb_substr($alias, 0, 14)." #".$row["id_agente"]." (".$row["count"].")";
|
||||
}
|
||||
$data[$name] = $row["count"];
|
||||
}
|
||||
|
@ -2597,4 +2597,4 @@ function recursive_get_dt_from_modules_tree (&$f_modules, $modules, $deep) {
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
@ -3991,7 +3991,7 @@ function reporting_sql($report, $content) {
|
||||
}
|
||||
else {
|
||||
$return['correct'] = 0;
|
||||
$return['error'] = __('Illegal query: Due security restrictions, there are some tokens or words you cannot use: *, delete, drop, alter, modify, password, pass, insert or update.');
|
||||
$return['error'] = __('Illegal query: Due security restrictions, there are some tokens or words you cannot use: *, delete, drop, alter, modify, union, password, pass, insert or update.');
|
||||
}
|
||||
|
||||
if ($config['metaconsole']) {
|
||||
@ -5857,25 +5857,6 @@ function reporting_custom_graph($report, $content, $type = 'dinamic',
|
||||
'id_agent_module'=>$graph_item['id_agent_module']);
|
||||
}
|
||||
|
||||
if($type_report == 'automatic_graph'){
|
||||
$label = (isset($content['style']['label'])) ? $content['style']['label'] : '';
|
||||
if (!empty($label)) {
|
||||
if ($config['metaconsole']) {
|
||||
$id_meta = metaconsole_get_id_server($content["server_name"]);
|
||||
$server = metaconsole_get_connection_by_id ($id_meta);
|
||||
metaconsole_connect($server);
|
||||
}
|
||||
$label = reporting_label_macro($content, $label);
|
||||
|
||||
if ($config['metaconsole']) {
|
||||
metaconsole_restore_db();
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$label = (isset($content['style']['label'])) ? $content['style']['label'] : '';
|
||||
$label = reporting_label_macro($content, $label);
|
||||
}
|
||||
|
||||
$labels[$graph_item['id_agent_module']] = $label;
|
||||
}
|
||||
}
|
||||
|
@ -444,6 +444,11 @@ function servers_get_info ($id_server = -1) {
|
||||
$server["type"] = "sync";
|
||||
$id_modulo = 0;
|
||||
break;
|
||||
case SERVER_TYPE_WUX:
|
||||
$server["img"] = html_print_image ("images/icono-wux.png", true, array ("title" => __('Wux server')));
|
||||
$server["type"] = "wux";
|
||||
$id_modulo = 0;
|
||||
break;
|
||||
default:
|
||||
$server["img"] = '';
|
||||
$server["type"] = "unknown";
|
||||
@ -759,6 +764,9 @@ function servers_show_type ($id) {
|
||||
case 7:
|
||||
return html_print_image("images/server_web.png", true, array("title" => "Pandora FMS WEB server"));
|
||||
break;
|
||||
case 8:
|
||||
return html_print_image("images/module-wux.png", true, array("title" => "Pandora FMS WUX server"));
|
||||
break;
|
||||
default:
|
||||
return "--";
|
||||
break;
|
||||
|
@ -2946,7 +2946,11 @@ function ui_print_agent_autocomplete_input($parameters) {
|
||||
if (isset($parameters['from_ux'])) {
|
||||
$from_ux_transaction = $parameters['from_ux'];
|
||||
}
|
||||
|
||||
|
||||
$from_wux_transaction = ''; //Default value
|
||||
if (isset($parameters['from_wux'])) {
|
||||
$from_wux_transaction = $parameters['from_wux'];
|
||||
}
|
||||
|
||||
$metaconsole_enabled = false; //Default value
|
||||
if (isset($parameters['metaconsole_enabled'])) {
|
||||
@ -3037,7 +3041,6 @@ function ui_print_agent_autocomplete_input($parameters) {
|
||||
if ($from_ux_transaction != "") {
|
||||
$javascript_code_function_select = '
|
||||
function function_select_' . $input_name . '(agent_name) {
|
||||
console.log(agent_name);
|
||||
$("#' . $selectbox_id . '").empty();
|
||||
|
||||
var inputs = [];
|
||||
@ -3064,6 +3067,35 @@ function ui_print_agent_autocomplete_input($parameters) {
|
||||
}
|
||||
';
|
||||
}
|
||||
elseif ($from_wux_transaction != "") {
|
||||
$javascript_code_function_select = '
|
||||
function function_select_' . $input_name . '(agent_name) {
|
||||
$("#' . $selectbox_id . '").empty();
|
||||
|
||||
var inputs = [];
|
||||
inputs.push ("id_agent=" + $("#' . $hidden_input_idagent_id . '").val());
|
||||
inputs.push ("get_agent_transactions=1");
|
||||
inputs.push ("page=enterprise/include/ajax/wux_transaction.ajax");
|
||||
|
||||
jQuery.ajax ({
|
||||
data: inputs.join ("&"),
|
||||
type: "POST",
|
||||
url: action="' . $javascript_ajax_page . '",
|
||||
dataType: "json",
|
||||
success: function (data) {
|
||||
if (data) {
|
||||
$("#' . $selectbox_id . '").append ($("<option value=0>None</option>"));
|
||||
jQuery.each (data, function (id, value) {
|
||||
$("#' . $selectbox_id . '").append ($("<option value=" + id + ">" + value + "</option>"));
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
}
|
||||
';
|
||||
}
|
||||
else {
|
||||
$javascript_code_function_select = '
|
||||
function function_select_' . $input_name . '(agent_name) {
|
||||
|
@ -624,8 +624,8 @@ function update_manager_extract_package() {
|
||||
|
||||
$extracted = false;
|
||||
|
||||
// Phar and exception working fine in 5.6.0 or higher
|
||||
if (PHP_VERSION_ID >= 50600) {
|
||||
// Phar and exception working fine in 5.5.0 or higher
|
||||
if (PHP_VERSION_ID >= 50505) {
|
||||
$phar = new PharData($path_package);
|
||||
try {
|
||||
$result = $phar->extractTo($config['attachment_store'] . "/downloads/",null, true);
|
||||
|
@ -178,7 +178,7 @@ function vbar_graph($flash_chart, $chart_data, $width, $height,
|
||||
$color, $legend, $long_index, $no_data_image, $xaxisname = "",
|
||||
$yaxisname = "", $water_mark = "", $font = '', $font_size = '',
|
||||
$unit = '', $ttl = 1, $homeurl = '', $backgroundColor = 'white',
|
||||
$from_ux = false) {
|
||||
$from_ux = false, $from_wux = false) {
|
||||
setup_watermark($water_mark, $water_mark_file, $water_mark_url);
|
||||
|
||||
if (empty($chart_data)) {
|
||||
@ -188,7 +188,7 @@ function vbar_graph($flash_chart, $chart_data, $width, $height,
|
||||
if ($flash_chart) {
|
||||
return flot_vcolumn_chart ($chart_data, $width, $height, $color,
|
||||
$legend, $long_index, $homeurl, $unit, $water_mark_url,
|
||||
$homedir,$font,$font_size, $from_ux);
|
||||
$homedir,$font,$font_size, $from_ux, $from_wux);
|
||||
}
|
||||
else {
|
||||
$graph = array();
|
||||
|
@ -34,7 +34,10 @@
|
||||
}
|
||||
if (dataObjects.length > 1) {
|
||||
dataObjects.forEach(function (element) {
|
||||
result = element;
|
||||
if (/^Avg.:/i.test(element.label))
|
||||
result = element;
|
||||
if (/^Percentil/i.test(element.label))
|
||||
result = element;
|
||||
});
|
||||
|
||||
// If the avg set is missing, retrieve the first set
|
||||
|
@ -132,7 +132,7 @@ function pandoraFlotPieCustom(graph_id, values, labels, width,
|
||||
var color = null;
|
||||
for (var i = 0; i < data.length; i++) {
|
||||
if (colors != '') {
|
||||
color = colors_data[i];
|
||||
color = colors[i];
|
||||
}
|
||||
var datos = data[i];
|
||||
data[i] = { label: labels[i], data: parseFloat(data[i]), color: color };
|
||||
@ -210,8 +210,8 @@ function pandoraFlotPieCustom(graph_id, values, labels, width,
|
||||
$('.legend>div').css('right',($('.legend>div').height()*-1));
|
||||
$('.legend>table').css('right',($('.legend>div').height()*-1));
|
||||
}
|
||||
$('.legend>table').css('border',"1px solid #E2E2E2");
|
||||
$('.legend>table').css('background-color',"#FFF");
|
||||
//$('.legend>table').css('border',"1px solid #E2E2E2");
|
||||
$('.legend>table').css('background-color',"transparent");
|
||||
|
||||
|
||||
var pielegends = $('#'+graph_id+' .pieLabelBackground');
|
||||
@ -269,6 +269,43 @@ function pandoraFlotPieCustom(graph_id, values, labels, width,
|
||||
set_watermark(graph_id, plot,
|
||||
$('#watermark_image_' + graph_id).attr('src'));
|
||||
}
|
||||
|
||||
window.onresize = function(event) {
|
||||
$.plot($('#' + graph_id), data, conf_pie);
|
||||
if (no_data == data.length) {
|
||||
$('#'+graph_id+' .overlay').remove();
|
||||
$('#'+graph_id+' .base').remove();
|
||||
$('#'+graph_id).prepend("<img style='width:50%;' src='images/no_data_toshow.png' />");
|
||||
}
|
||||
var legends = $('#'+graph_id+' .legendLabel');
|
||||
var j = 0;
|
||||
legends.each(function () {
|
||||
//$(this).css('width', $(this).width());
|
||||
$(this).css('font-size', font_size+'pt');
|
||||
$(this).removeClass("legendLabel");
|
||||
$(this).addClass(font);
|
||||
$(this).text(legend[j]);
|
||||
j++;
|
||||
});
|
||||
|
||||
if ($('input[name="custom_graph"]').val()) {
|
||||
$('.legend>div').css('right',($('.legend>div').height()*-1));
|
||||
$('.legend>table').css('right',($('.legend>div').height()*-1));
|
||||
}
|
||||
//$('.legend>table').css('border',"1px solid #E2E2E2");
|
||||
$('.legend>table').css('background-color',"transparent");
|
||||
|
||||
|
||||
var pielegends = $('#'+graph_id+' .pieLabelBackground');
|
||||
pielegends.each(function () {
|
||||
$(this).css('transform', "rotate(-35deg)").css('color', 'black');
|
||||
});
|
||||
var labelpielegends = $('#'+graph_id+' .pieLabel');
|
||||
labelpielegends.each(function () {
|
||||
$(this).css('transform', "rotate(-35deg)").css('color', 'black');
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
function pandoraFlotHBars(graph_id, values, labels, water_mark,
|
||||
@ -457,7 +494,7 @@ function showTooltip(x, y, color, contents) {
|
||||
}).appendTo("body").fadeIn(200);
|
||||
}
|
||||
|
||||
function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, water_mark, maxvalue, water_mark, separator, separator2, font, font_size , from_ux) {
|
||||
function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors, water_mark, maxvalue, water_mark, separator, separator2, font, font_size , from_ux, from_wux) {
|
||||
values = values.split(separator2);
|
||||
legend = legend.split(separator);
|
||||
font = font.split("/").pop().split(".").shift();
|
||||
@ -552,6 +589,18 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors,
|
||||
}
|
||||
};
|
||||
|
||||
if(from_wux){
|
||||
options.series.bars.barWidth = 0.5;
|
||||
options.grid.aboveData = true;
|
||||
options.grid.borderWidth = 0;
|
||||
options.grid.markings = [ { xaxis: { from: -0.25, to: -0.25 }, color: "#000" },
|
||||
{ yaxis: { from: 0, to: 0 }, color: "#000" }];
|
||||
options.grid.markingsLineWidth = 0.3;
|
||||
|
||||
options.xaxis.tickLength = 0;
|
||||
options.yaxis.tickLength = 0;
|
||||
}
|
||||
|
||||
if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent))
|
||||
options.xaxis.labelWidth = 100;
|
||||
|
||||
@ -560,14 +609,15 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors,
|
||||
$('#' + graph_id).css("margin-left","auto");
|
||||
$('#' + graph_id).css("margin-right","auto");
|
||||
//~ $('#' + graph_id).find('div.legend-tooltip').tooltip({ track: true });
|
||||
|
||||
$('#'+graph_id+' .xAxis .tickLabel')
|
||||
.css('transform', 'rotate(-45deg)')
|
||||
.css('max-width','100px')
|
||||
.find('div')
|
||||
.css('position', 'relative')
|
||||
.css('top', '+10px')
|
||||
.css('left', '-30px');
|
||||
/*
|
||||
$('#'+graph_id+' .xAxis .tickLabel')
|
||||
.css('transform', 'rotate(-45deg)')
|
||||
.css('max-width','100px')
|
||||
.find('div')
|
||||
.css('position', 'relative')
|
||||
.css('top', '+10px')
|
||||
.css('left', '-30px');
|
||||
*/
|
||||
if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent))
|
||||
$('#'+graph_id+' .xAxis .tickLabel')
|
||||
.find('div')
|
||||
@ -588,7 +638,7 @@ function pandoraFlotVBars(graph_id, values, labels, labels_long, legend, colors,
|
||||
}
|
||||
|
||||
format.push([i,
|
||||
'<div class="'+font+'" title="'+title+'" style="word-break: normal; max-width: 100px;font-size:'+font_size+'pt !important;">'
|
||||
'<div class="'+font+'" title="'+title+'" style="word-break: normal; transform: rotate(-45deg); position:relative; top:+30px; left:-20px; max-width: 100px;font-size:'+font_size+'pt !important;">'
|
||||
+ label
|
||||
+ '</div>']);
|
||||
}
|
||||
@ -839,16 +889,11 @@ function pandoraFlotArea(graph_id, values, labels, labels_long, legend,
|
||||
|
||||
// Prepared to turn series with a checkbox
|
||||
// var showed = new Array();
|
||||
var min_check = 0;
|
||||
|
||||
for (i = 0; i < values.length; i++) {
|
||||
var serie = values[i].split(separator);
|
||||
var aux = new Array();
|
||||
$.each(serie, function(i, v) {
|
||||
if(v < 0){
|
||||
if(min_check > parseFloat(v)){
|
||||
min_check = v;
|
||||
}
|
||||
}
|
||||
aux.push([i, v]);
|
||||
});
|
||||
|
||||
@ -932,9 +977,7 @@ function pandoraFlotArea(graph_id, values, labels, labels_long, legend,
|
||||
// Prepared to turn series with a checkbox
|
||||
// showed[i] = true;
|
||||
}
|
||||
if(min_check != 0){
|
||||
min_check = min_check -5;
|
||||
}
|
||||
|
||||
// If threshold and up are the same, that critical or warning is disabled
|
||||
if (yellow_threshold == yellow_up) yellow_inverse = false;
|
||||
if (red_threshold == red_up) red_inverse = false;
|
||||
@ -1496,7 +1539,6 @@ function pandoraFlotArea(graph_id, values, labels, labels_long, legend,
|
||||
position: 'left',
|
||||
font: font,
|
||||
reserveSpace: true,
|
||||
min: min_check
|
||||
}],
|
||||
legend: {
|
||||
position: 'se',
|
||||
|
@ -752,7 +752,7 @@ function flot_hcolumn_chart ($graph_data, $width, $height, $water_mark, $font =
|
||||
}
|
||||
|
||||
// Returns a 3D column chart
|
||||
function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $long_index, $homeurl, $unit, $water_mark, $homedir, $font, $font_size, $from_ux) {
|
||||
function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $long_index, $homeurl, $unit, $water_mark, $homedir, $font, $font_size, $from_ux, $from_wux) {
|
||||
global $config;
|
||||
|
||||
include_javascript_dependencies_flot_graph();
|
||||
@ -835,10 +835,15 @@ function flot_vcolumn_chart ($graph_data, $width, $height, $color, $legend, $lon
|
||||
$return .= "<script type='text/javascript'>";
|
||||
|
||||
if ($from_ux) {
|
||||
$return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true)";
|
||||
if($from_wux){
|
||||
$return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, true)";
|
||||
}
|
||||
else{
|
||||
$return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, true, false)";
|
||||
}
|
||||
}
|
||||
else {
|
||||
$return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, false)";
|
||||
$return .= "pandoraFlotVBars('$graph_id', '$values', '$labels', '$labels', '$legend', '$colors', false, $max, '$water_mark', '$separator', '$separator2','$font',$font_size, false, false)";
|
||||
}
|
||||
|
||||
$return .= "</script>";
|
||||
|
@ -1331,8 +1331,8 @@ function Gauge(placeholderName, configuration, font)
|
||||
function print_phases_donut (recipient, phases) {
|
||||
var svg = d3.select(recipient)
|
||||
.append("svg")
|
||||
.attr("width", 600)
|
||||
.attr("height", 300)
|
||||
.attr("width", 800)
|
||||
.attr("height", 400)
|
||||
.append("g");
|
||||
|
||||
svg.append("g")
|
||||
@ -1360,6 +1360,8 @@ function print_phases_donut (recipient, phases) {
|
||||
.innerRadius(radius * 0.9)
|
||||
.outerRadius(radius * 0.9);
|
||||
|
||||
width = 800;
|
||||
height = 400;
|
||||
svg.attr("transform", "translate(" + width / 2 + "," + height / 2 + ")");
|
||||
|
||||
var key = function(d){ return d.data.label; };
|
||||
@ -1424,15 +1426,15 @@ function print_phases_donut (recipient, phases) {
|
||||
return d.data.label;
|
||||
})
|
||||
.style("font-family", "Verdana")
|
||||
.style("font-size", "10px")
|
||||
.style("font-size", "15px")
|
||||
.append("tspan")
|
||||
.attr("dy", "1.4em")
|
||||
.attr("dx", "-6em")
|
||||
.attr("dy", "1.2em")
|
||||
.attr("dx", "-2.8em")
|
||||
.text(function(d) {
|
||||
return d.data.label2 + "ms";
|
||||
})
|
||||
.style("font-family", "Verdana")
|
||||
.style("font-size", "10px");
|
||||
.style("font-size", "15px");
|
||||
|
||||
function midAngle(d){
|
||||
return d.startAngle + (d.endAngle - d.startAngle)/2;
|
||||
|
@ -68,7 +68,6 @@ Apart from the defined module macros, the following macros are also available:
|
||||
<li>_alert_warning_instructions_: Instructions for WARNING status contained in the module.</li>
|
||||
<li>_alert_unknown_instructions_: Instructions for UNKNOWN status contained in the module.</li>
|
||||
<li>_modulegraph_nh_: (Only for alerts that use the command eMail) Returns an image of a module graph with a period of n hours (eg. _modulegraph_24h_). A correct setup of the connection between the server and the console's api is required. This setup is done into the server's configuration file.</li>
|
||||
<li>_modulegraphth_<i>n</i>h_:Same operation as the previous macro only with the critical and warning thresholds of the module provided they are defined.</li>
|
||||
<li>_homeurl_ : It is a link of the public URL this must be configured in the general options of the setup.</li>
|
||||
</ul>
|
||||
<p>
|
||||
|
@ -68,7 +68,6 @@ Besides the defined module macros, the following macros are available:
|
||||
Returns an image encoded in base64 of a module’s graph with a period of <i>n</i> hours (eg. _modulegraph_24h_).
|
||||
A correct setup of the connection between the server and the console's API is required.
|
||||
This setup is done on the server's configuration file.</li>
|
||||
<li>_modulegraphth_<i>n</i>h_:Same operation as the previous macro only with the critical and warning thresholds of the module provided they are defined.</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
|
@ -4,18 +4,72 @@
|
||||
*/
|
||||
?>
|
||||
<h1>Module macros</h1>
|
||||
|
||||
Any number of custom module macros may be defined. The recommended format for macro names is:
|
||||
|
||||
<p>
|
||||
Any number of custom module macros may be defined. The recommended format for macro names is:
|
||||
</p>
|
||||
<pre>
|
||||
_macroname_
|
||||
_macroname_
|
||||
</pre>
|
||||
|
||||
For example:
|
||||
<ul>
|
||||
<li>_technology_</li>
|
||||
<li>_modulepriority_</li>
|
||||
<li>_contactperson_</li>
|
||||
</ul>
|
||||
<p>
|
||||
For example:
|
||||
</p>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_technology_
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_modulepriority_
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_contactperson_
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
This macros can be used in module alerts.
|
||||
<p>
|
||||
This macros can be used in module alerts.
|
||||
</p>
|
||||
|
||||
<h2>Si el módulo es de tipo analisis de módulo web:</h2>
|
||||
|
||||
<p>
|
||||
Las macros dinámicas tendrán un formato especial que empieza por @ y tendrán estas posibles sustituciones:
|
||||
</p>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT (fecha/hora actual con formato definido por el usuario)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nh (horas)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nm (minutos)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nd (días)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_ns (segundos)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nM (mes)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nY (años)
|
||||
</li>
|
||||
</ol>
|
||||
<p>
|
||||
Donde “n” puede ser un numero sin signo (positivo) o negativo.
|
||||
</p>
|
||||
<p>
|
||||
Y FORMAT sigue el standard de strftime de perl:
|
||||
http://search.cpan.org/~dexter/POSIX-strftime-GNU-0.02/lib/POSIX/strftime/GNU.pm
|
||||
</p>
|
||||
<p>
|
||||
Ejemplos:
|
||||
</p>
|
||||
<pre>
|
||||
@DATE_%Y-%m-%d %H:%M:%S
|
||||
@DATE_%H:%M:%S_300s
|
||||
@DATE_%H:%M:%S_-1h
|
||||
</pre>
|
@ -8,7 +8,6 @@
|
||||
|
||||
The following macros are also available: <br />
|
||||
<ul>
|
||||
Only if you select one graph for each agent.<br />
|
||||
<li><b>_agent_ </b>: Name of the agent that you selected in report item.<li />
|
||||
<li><b>_agentdescription_ </b>: Description of the agent that you selected in report item.<li />
|
||||
<li><b>_agentgroup_ </b>: Agent group name.<li />
|
||||
|
304
pandora_console/include/help/en/help_wux_console.php
Normal file
@ -0,0 +1,304 @@
|
||||
<h1>Monitorización de Experiencia de Usuario Web (WUX)</h1>
|
||||
<h2>Introducción</h2>
|
||||
|
||||
<p>
|
||||
Pandora WUX es un componente interno de Pandora FMS que permite a los usuarios automatizar sus sesiones de navegación web. Genera en Pandora FMS un informe con los resultados de las ejecuciones, tiempos empleados, y capturas con los posibles errores encontrados. Es capaz de dividir las sesiones de navegación en fases para simplificar la vista y depurar posibles cuellos de botella.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Pandora WUX utiliza el robot de navegación de Pandora (PWR - Pandora Web Robot) para automatizar las sesiones de navegación
|
||||
</p>
|
||||
|
||||
<h2>Grabar una sesión de navegación web</h2>
|
||||
<h4>Grabar una sesión PWR</h4>
|
||||
|
||||
<p>
|
||||
Antes de monitorizar una experiencia de usuario debemos hacer la grabación. Dependiendo del tipo de tecnología que hayamos elegido utilizaremos un sistema de grabación u otro.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Para realizar la grabación de una navegación con PWR necesitaremos:
|
||||
</b>
|
||||
</p>
|
||||
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Navegador web Firefox versión 47.0.1 (descargable en:
|
||||
<a rel="nofollow" class="external free" href="https://ftp.mozilla.org/pub/firefox/releases/47.0.1/">https://ftp.mozilla.org/pub/firefox/releases/47.0.1/</a>).
|
||||
.</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Extensión Selenium IDE (descargable en:
|
||||
<a rel="nofollow" class="external free" href="https://addons.mozilla.org/es/firefox/addon/selenium-ide/">https://addons.mozilla.org/es/firefox/addon/selenium-ide/</a>).
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<p>
|
||||
Para instalar correctamente la versión 47.0.1 de Firefox hay que descargarla desde la URL proporcionada anteriormente. En sistemas Windows habrá que añadir el ejecutable al PATH del sistema.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux6.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez descargado mostraremos el icono del entorno de grabación mediante las opciones de personalización de Firefox:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux7.JPG", false, array('style' => 'width:295px;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux9.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez colocado el acceso iniciamos el grabador:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux10.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Desde este momento podremos navegar por el sitio web que queramos monitorizar y las diferentes acciones de cada paso que avancemos irán apareciendo en el grabador.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Para detener la grabación utilizaremos el siguiente botón, situado en la parte superior derecha del grabador:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux11.JPG", false, array('style' => 'width:33px;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez completadas las acciones, podemos realizar comprobaciones sobre la página, por ejemplo verificar la existencia de un texto determinado para asegurarnos de que la página cargada es la correcta. Para ello haremos click derecho sobre una sección de texto en la ventana del navegador mientras continuamos grabando, y seleccionamos la opción <i>verifyText</i>:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux13.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Aparecerá un nuevo paso en el grabador indicando la acción de comprobación de texto indicada:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux14.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Podemos reproducir la secuencia completa mediante el botón <i>Play entire test suite</i> y comprobar que finaliza correctamente:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux15.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez verificada la validez de la secuencia de navegación, la guardaremos (Archivo -> Save Test Case) para ejecutarla posteriormente con Pandora WUX. El fichero resultante será un documento HTML que Pandora WUX interpretará.
|
||||
</p>
|
||||
|
||||
<h4>Grabar una sesión transaccional con Pandora WUX PWR</h4>
|
||||
|
||||
<p>
|
||||
Pandora WUX en modo PWR (Pandora Web Robot) permite dividir la monitorización de la navegación de un sitio web en múltiples módulos, que representarán cada uno de los pasos realizados.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Para insertar un nuevo punto de control y generar los módulos de fase (hasta ese punto) haga clic derecho en el punto donde desea identificar el comienzo de fase.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux16.JPG", false, array('style' => 'width:436;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Como comentario pondremos el siguiente texto:
|
||||
</p>
|
||||
|
||||
<pre>
|
||||
phase_start:nombre_de_fase
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
La fase englobará el tiempo y resultado de todos los comandos que se encuentren hasta el siguiente comentario:
|
||||
</p>
|
||||
|
||||
<pre>
|
||||
phase_end:nombre_de_fase
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
Todos los comandos que se ejecuten entre una etiqueta phase_start y phase_end se englobarán dentro de esa fase.
|
||||
</p>
|
||||
|
||||
<h2>Visualización de los datos</h2>
|
||||
|
||||
<p>
|
||||
WUX provee al usuario un conjunto de interfaces para recibir información en todo momento de los resultados de las ejecuciones de las sesiones de navegación:
|
||||
</p>
|
||||
|
||||
<h3>Vista de módulos</h3>
|
||||
|
||||
<p>
|
||||
Cada módulo de tipo análisis web, generará una serie de sub-módulos, estos pueden visualizarse de manera más clara pulsando "mostar en modo jeráquico".
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v1.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
En la vista de árbol los elementos apararecen directamente jerarquizados, simplificando la vista.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v2.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<h3>Vista de consola WUX</h3>
|
||||
<p>
|
||||
En esta vista podemos encontrar toda la infomación que el sistema WUX ha obtenido de la sesión de navegación configurada:
|
||||
</p>
|
||||
<p>
|
||||
<b><u>Nota</u>:</b> Si hemos definido fases en nuestra sesión de navegación, se mostrarán en esta vista de una forma sencilla y clara (ver apartado de grabación <i>sesión transaccional con Pandora WUX PWR)</i>.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v3.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<h4> Sección Resultado Global: </h4>
|
||||
<p>
|
||||
Muestra el estado general de nuestra transacción:
|
||||
</p>
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Esta puede tener tres estados:
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Correcto:</i> Cuando todas las fases de la transacción sean correctas.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Incorrecto:</i> Si alguna de las fases de la transacción ha fallado. En ese caso, se mostrara una icono de una lupa que enlaza a la captura de pantalla del punto de la sesión de navegación en que se ha producido el fallo.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Desconocido:</i> Si el servidor encuentra problemas para procesar la sesión o hay fallos de configuración.
|
||||
</li>
|
||||
</ol>
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el tiempo transcurrido desde la última ejecución de la sesión de navegación.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el tiempo total que ha tardado en realizarse dicha sesión de navegación, independientemente de su estado.
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h4>Sección Resultados de la ejecución de la transacción:</h4>
|
||||
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el estado y el tiempo empleado en ejecutar la sesión de navegación.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
En caso de fallo, se mostrará el icono que enlaza con la captura del momento del error.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Si hemos definido fases en nuestra sesión, entonces se mostrará el estado de cada una de las fases, asi como el tiempo que tarda en realizarse cada una de ellas y su contribución al tiempo global.
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<p>
|
||||
Gráfica que muestra el tiempo que tarda en realizar cada fase de la transacción y el estado de dicha fase, si no tenemos fases definidas, se mostrará en bloque el tiempo global empleado en la sesión.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Gráfica de estadisticas aparecera siempre y cuando hayamos especificado en la creación del módulo, la opción <i style="font-family: 'lato-bolder'; font-size: 12pt;">ejecutar pruebas de rendimiento</i> <b style="font-family: 'lato-bolder'; font-size: 12pt;">y se ha definido un objetivo para las mismas</b> (campo <i style="font-family: 'lato-bolder'; font-size: 12pt;">sitio web objetivo</i>).
|
||||
</p>
|
||||
<p>
|
||||
Las estadísticas a mostrar son:
|
||||
</p>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TT:
|
||||
</b>
|
||||
Tiempo total en obtener el sitio web.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TDNS:
|
||||
</b>
|
||||
Tiempo total en resolver la dirección IP del objetivo.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTCP:
|
||||
</b>
|
||||
Tiempo empleado en conectar vía TCP.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TSSL:
|
||||
</b>
|
||||
Tiempo empleado en establecer comunicación SSL.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TST :
|
||||
</b>
|
||||
Tiempo hasta que inició la transferencia de datos.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTC :
|
||||
</b>
|
||||
Tiempo transfiriendo datos, agrupará todos los tiempos de transferencia de recursos.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTR :
|
||||
</b>
|
||||
Tiempo empleado en transferir el recurso X, agrupando todas las imágenes en “image”.
|
||||
</li>
|
||||
</ol>
|
||||
</p>
|
||||
|
||||
<h4>Historial de trasacción:</h4>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el histórico de las ejecuciones de la sesión de navegación web.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
En el caso de haber ejecuciones fallidas, se mostrará un enlace donde consultar la imagen del error.
|
||||
</li>
|
||||
</ol>
|
@ -68,7 +68,6 @@ Además de las macros de módulo definidas, las siguientes macros están disponi
|
||||
Devuelve una imagen codificada en base64 de una gráfica del módulo con un período de <i>n</i> horas (eg. _modulegraph_24h_).
|
||||
Requiere de una configuración correcta de la conexión del servidor a la consola vía api,
|
||||
la cual se realiza en el fichero de configuración del servidor.</li>
|
||||
<li>_modulegraphth_<i>n</i>h_:mismo funcionamiento que la macro anterior solo que con los umbrales critical y warning del modulo siempre que estos esten definidos</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
|
@ -4,18 +4,73 @@
|
||||
*/
|
||||
?>
|
||||
<h1>Macros de módulo</h1>
|
||||
|
||||
Se puede definir cualquier número de macros de módulo. El formato recomendado para los nombres de macros es el siguiente:
|
||||
|
||||
<p>
|
||||
Se puede definir cualquier número de macros de módulo. El formato recomendado para los nombres de macros es el siguiente:
|
||||
</p>
|
||||
<pre>
|
||||
_macroname_
|
||||
_macroname_
|
||||
</pre>
|
||||
|
||||
Por ejemplo:
|
||||
<ul>
|
||||
<li>_technology_</li>
|
||||
<li>_modulepriority_</li>
|
||||
<li>_contactperson_</li>
|
||||
</ul>
|
||||
<p>
|
||||
Por ejemplo:
|
||||
</p>
|
||||
|
||||
Estas macros se pueden utilizar en las alertas de módulos.
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_technology_
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_modulepriority_
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
_contactperson_
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<p>
|
||||
Estas macros se pueden utilizar en las alertas de módulos.
|
||||
</p>
|
||||
|
||||
<h2>Si el módulo es de tipo analisis de módulo web:</h2>
|
||||
|
||||
<p>
|
||||
Las macros dinámicas tendrán un formato especial que empieza por @ y tendrán estas posibles sustituciones:
|
||||
</p>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT (fecha/hora actual con formato definido por el usuario)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nh (horas)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nm (minutos)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nd (días)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_ns (segundos)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nM (mes)
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
@DATE_FORMAT_nY (años)
|
||||
</li>
|
||||
</ol>
|
||||
<p>
|
||||
Donde “n” puede ser un numero sin signo (positivo) o negativo.
|
||||
</p>
|
||||
<p>
|
||||
Y FORMAT sigue el standard de strftime de perl:
|
||||
http://search.cpan.org/~dexter/POSIX-strftime-GNU-0.02/lib/POSIX/strftime/GNU.pm
|
||||
</p>
|
||||
<p>
|
||||
Ejemplos:
|
||||
</p>
|
||||
<pre>
|
||||
@DATE_%Y-%m-%d %H:%M:%S
|
||||
@DATE_%H:%M:%S_300s
|
||||
@DATE_%H:%M:%S_-1h
|
||||
</pre>
|
@ -8,7 +8,6 @@
|
||||
|
||||
Lista de las macros admitidas en este campo: <br />
|
||||
<ul>
|
||||
Solamente si seleccionas una gráfica por cada agente.<br />
|
||||
<li><b>_agent_ </b>: Nombre del agente que ha seleccionado en el elemento del informe.<li />
|
||||
<li><b>_agentdescription_ </b>: Descripción del agente que ha seleccionado en el elemento del informe.<li />
|
||||
<li><b>_agentgroup_ </b>: Grupo del agente que ha seleccionado en el elemento del informe<li />
|
||||
|
304
pandora_console/include/help/es/help_wux_console.php
Normal file
@ -0,0 +1,304 @@
|
||||
<h1>Monitorización de Experiencia de Usuario Web (WUX)</h1>
|
||||
<h2>Introducción</h2>
|
||||
|
||||
<p>
|
||||
Pandora WUX es un componente interno de Pandora FMS que permite a los usuarios automatizar sus sesiones de navegación web. Genera en Pandora FMS un informe con los resultados de las ejecuciones, tiempos empleados, y capturas con los posibles errores encontrados. Es capaz de dividir las sesiones de navegación en fases para simplificar la vista y depurar posibles cuellos de botella.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Pandora WUX utiliza el robot de navegación de Pandora (PWR - Pandora Web Robot) para automatizar las sesiones de navegación
|
||||
</p>
|
||||
|
||||
<h2>Grabar una sesión de navegación web</h2>
|
||||
<h4>Grabar una sesión PWR</h4>
|
||||
|
||||
<p>
|
||||
Antes de monitorizar una experiencia de usuario debemos hacer la grabación. Dependiendo del tipo de tecnología que hayamos elegido utilizaremos un sistema de grabación u otro.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Para realizar la grabación de una navegación con PWR necesitaremos:
|
||||
</b>
|
||||
</p>
|
||||
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Navegador web Firefox versión 47.0.1 (descargable en:
|
||||
<a rel="nofollow" class="external free" href="https://ftp.mozilla.org/pub/firefox/releases/47.0.1/">https://ftp.mozilla.org/pub/firefox/releases/47.0.1/</a>).
|
||||
.</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Extensión Selenium IDE (descargable en:
|
||||
<a rel="nofollow" class="external free" href="https://addons.mozilla.org/es/firefox/addon/selenium-ide/">https://addons.mozilla.org/es/firefox/addon/selenium-ide/</a>).
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<p>
|
||||
Para instalar correctamente la versión 47.0.1 de Firefox hay que descargarla desde la URL proporcionada anteriormente. En sistemas Windows habrá que añadir el ejecutable al PATH del sistema.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux6.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez descargado mostraremos el icono del entorno de grabación mediante las opciones de personalización de Firefox:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux7.JPG", false, array('style' => 'width:295px;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux9.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez colocado el acceso iniciamos el grabador:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux10.JPG", false, array('style' => 'width: 90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Desde este momento podremos navegar por el sitio web que queramos monitorizar y las diferentes acciones de cada paso que avancemos irán apareciendo en el grabador.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Para detener la grabación utilizaremos el siguiente botón, situado en la parte superior derecha del grabador:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux11.JPG", false, array('style' => 'width:33px;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez completadas las acciones, podemos realizar comprobaciones sobre la página, por ejemplo verificar la existencia de un texto determinado para asegurarnos de que la página cargada es la correcta. Para ello haremos click derecho sobre una sección de texto en la ventana del navegador mientras continuamos grabando, y seleccionamos la opción <i>verifyText</i>:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux13.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Aparecerá un nuevo paso en el grabador indicando la acción de comprobación de texto indicada:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux14.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Podemos reproducir la secuencia completa mediante el botón <i>Play entire test suite</i> y comprobar que finaliza correctamente:
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux15.JPG", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Una vez verificada la validez de la secuencia de navegación, la guardaremos (Archivo -> Save Test Case) para ejecutarla posteriormente con Pandora WUX. El fichero resultante será un documento HTML que Pandora WUX interpretará.
|
||||
</p>
|
||||
|
||||
<h4>Grabar una sesión transaccional con Pandora WUX PWR</h4>
|
||||
|
||||
<p>
|
||||
Pandora WUX en modo PWR (Pandora Web Robot) permite dividir la monitorización de la navegación de un sitio web en múltiples módulos, que representarán cada uno de los pasos realizados.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Para insertar un nuevo punto de control y generar los módulos de fase (hasta ese punto) haga clic derecho en el punto donde desea identificar el comienzo de fase.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/Ux16.JPG", false, array('style' => 'width:436;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Como comentario pondremos el siguiente texto:
|
||||
</p>
|
||||
|
||||
<pre>
|
||||
phase_start:nombre_de_fase
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
La fase englobará el tiempo y resultado de todos los comandos que se encuentren hasta el siguiente comentario:
|
||||
</p>
|
||||
|
||||
<pre>
|
||||
phase_end:nombre_de_fase
|
||||
</pre>
|
||||
|
||||
<p>
|
||||
Todos los comandos que se ejecuten entre una etiqueta phase_start y phase_end se englobarán dentro de esa fase.
|
||||
</p>
|
||||
|
||||
<h2>Visualización de los datos</h2>
|
||||
|
||||
<p>
|
||||
WUX provee al usuario un conjunto de interfaces para recibir información en todo momento de los resultados de las ejecuciones de las sesiones de navegación:
|
||||
</p>
|
||||
|
||||
<h3>Vista de módulos</h3>
|
||||
|
||||
<p>
|
||||
Cada módulo de tipo análisis web, generará una serie de sub-módulos, estos pueden visualizarse de manera más clara pulsando "mostar en modo jeráquico".
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v1.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
En la vista de árbol los elementos apararecen directamente jerarquizados, simplificando la vista.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v2.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<h3>Vista de consola WUX</h3>
|
||||
<p>
|
||||
En esta vista podemos encontrar toda la infomación que el sistema WUX ha obtenido de la sesión de navegación configurada:
|
||||
</p>
|
||||
<p>
|
||||
<b><u>Nota</u>:</b> Si hemos definido fases en nuestra sesión de navegación, se mostrarán en esta vista de una forma sencilla y clara (ver apartado de grabación <i>sesión transaccional con Pandora WUX PWR)</i>.
|
||||
</p>
|
||||
|
||||
<p style="text-align: center">
|
||||
<?php
|
||||
html_print_image("images/help/WUX_v3.png", false, array('style' => 'width:90%;'));
|
||||
?>
|
||||
</p>
|
||||
|
||||
<h4> Sección Resultado Global: </h4>
|
||||
<p>
|
||||
Muestra el estado general de nuestra transacción:
|
||||
</p>
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Esta puede tener tres estados:
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Correcto:</i> Cuando todas las fases de la transacción sean correctas.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Incorrecto:</i> Si alguna de las fases de la transacción ha fallado. En ese caso, se mostrara una icono de una lupa que enlaza a la captura de pantalla del punto de la sesión de navegación en que se ha producido el fallo.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<i style="font-family: 'lato-bolder'; font-size: 12pt;">Desconocido:</i> Si el servidor encuentra problemas para procesar la sesión o hay fallos de configuración.
|
||||
</li>
|
||||
</ol>
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el tiempo transcurrido desde la última ejecución de la sesión de navegación.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el tiempo total que ha tardado en realizarse dicha sesión de navegación, independientemente de su estado.
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h4>Sección Resultados de la ejecución de la transacción:</h4>
|
||||
|
||||
<ol style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el estado y el tiempo empleado en ejecutar la sesión de navegación.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
En caso de fallo, se mostrará el icono que enlaza con la captura del momento del error.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Si hemos definido fases en nuestra sesión, entonces se mostrará el estado de cada una de las fases, asi como el tiempo que tarda en realizarse cada una de ellas y su contribución al tiempo global.
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<p>
|
||||
Gráfica que muestra el tiempo que tarda en realizar cada fase de la transacción y el estado de dicha fase, si no tenemos fases definidas, se mostrará en bloque el tiempo global empleado en la sesión.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Gráfica de estadisticas aparecera siempre y cuando hayamos especificado en la creación del módulo, la opción <i style="font-family: 'lato-bolder'; font-size: 12pt;">ejecutar pruebas de rendimiento</i> <b style="font-family: 'lato-bolder'; font-size: 12pt;">y se ha definido un objetivo para las mismas</b> (campo <i style="font-family: 'lato-bolder'; font-size: 12pt;">sitio web objetivo</i>).
|
||||
</p>
|
||||
<p>
|
||||
Las estadísticas a mostrar son:
|
||||
</p>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TT:
|
||||
</b>
|
||||
Tiempo total en obtener el sitio web.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TDNS:
|
||||
</b>
|
||||
Tiempo total en resolver la dirección IP del objetivo.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTCP:
|
||||
</b>
|
||||
Tiempo empleado en conectar vía TCP.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TSSL:
|
||||
</b>
|
||||
Tiempo empleado en establecer comunicación SSL.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TST :
|
||||
</b>
|
||||
Tiempo hasta que inició la transferencia de datos.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTC :
|
||||
</b>
|
||||
Tiempo transfiriendo datos, agrupará todos los tiempos de transferencia de recursos.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
<b style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Stats_TTR :
|
||||
</b>
|
||||
Tiempo empleado en transferir el recurso X, agrupando todas las imágenes en “image”.
|
||||
</li>
|
||||
</ol>
|
||||
</p>
|
||||
|
||||
<h4>Historial de trasacción:</h4>
|
||||
<ol>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
Muestra el histórico de las ejecuciones de la sesión de navegación web.
|
||||
</li>
|
||||
<li style="font-family: 'lato-bolder'; font-size: 12pt;">
|
||||
En el caso de haber ejecuciones fallidas, se mostrará un enlace donde consultar la imagen del error.
|
||||
</li>
|
||||
</ol>
|
@ -307,12 +307,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -347,12 +342,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -375,12 +365,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -415,12 +400,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -445,12 +425,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -485,12 +460,7 @@ function change_shape(id_db_node) {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
}
|
||||
@ -3184,12 +3154,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3223,12 +3188,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3256,12 +3216,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3299,12 +3254,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3334,12 +3284,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3377,12 +3322,7 @@ function draw_elements_graph() {
|
||||
})
|
||||
.on("click", selected_node)
|
||||
.on("dblclick", function(d) {
|
||||
if (d.type == undefined) {
|
||||
move_to_networkmap(d);
|
||||
}
|
||||
else {
|
||||
edit_node(d, true);
|
||||
}
|
||||
edit_node(d, true);
|
||||
})
|
||||
.on("contextmenu", function(d) { show_menu("node", d);});
|
||||
|
||||
@ -3413,29 +3353,6 @@ function draw_elements_graph() {
|
||||
node.exit().remove();
|
||||
}
|
||||
|
||||
function move_to_networkmap (node) {
|
||||
var params = [];
|
||||
params.push("get_networkmap_from_fictional=1");
|
||||
params.push("id=" + node.id_db);
|
||||
params.push("id_map=" + node.map_id);
|
||||
params.push("page=enterprise/operation/agentes/pandora_networkmap.view");
|
||||
|
||||
jQuery.ajax ({
|
||||
data: params.join ("&"),
|
||||
dataType: 'json',
|
||||
type: 'POST',
|
||||
url: action="ajax.php",
|
||||
success: function (data) {
|
||||
if (data['correct']) {
|
||||
window.location="index.php?sec=network&sec2=operation/agentes/pandora_networkmap&tab=view&id_networkmap=" + data['id_networkmap'];
|
||||
}
|
||||
else {
|
||||
edit_node(node, true);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function choose_group_for_show_agents() {
|
||||
if (enterprise_installed) {
|
||||
group = $("#group_for_show_agents option:selected").val();
|
||||
|
@ -1193,4 +1193,31 @@ function htmlEncode(value){
|
||||
|
||||
function htmlDecode(value){
|
||||
return $('<div/>').html(value).text();
|
||||
}
|
||||
|
||||
function pagination_show_more(params, message){
|
||||
//value input hidden for save limit
|
||||
var value_offset = $('#hidden-offset').val();
|
||||
//For each execution offset + limit
|
||||
var offset = parseInt(value_offset) + params['limit'];
|
||||
//save new value innput hidden
|
||||
$('#hidden-offset').val(offset);
|
||||
//add array value offset
|
||||
params['offset'] = offset;
|
||||
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "ajax.php",
|
||||
data: params,
|
||||
success: function(data) {
|
||||
if(data == ''){
|
||||
$('#container_error').empty();
|
||||
$('#container_error').append('<h4>'+ message +'</h4>');
|
||||
}
|
||||
else{
|
||||
$('#container_pag').append(data);
|
||||
}
|
||||
},
|
||||
datatype: "html"
|
||||
});
|
||||
}
|
@ -437,7 +437,15 @@ function configure_modules_form () {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
moduletype = $("#hidden-id_module_type").val ();
|
||||
if (moduletype == 25) {
|
||||
if ($("#custom_integer_1").val () == 0) {
|
||||
$("#custom_integer_1").focus ();
|
||||
$("#message").showMessage (no_execute_test_from);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
module = $("#id_module_type").attr ("value");
|
||||
|
||||
if (id_modules_icmp.in_array (module) || id_modules_tcp.in_array (module) || id_modules_snmp.in_array (module)) {
|
||||
@ -899,3 +907,27 @@ function delete_macro_local_component(prefix) {
|
||||
var $row2 = $('#'+prefix+nrow2).remove();
|
||||
}
|
||||
|
||||
//Add a new module macro
|
||||
function add_macro () {
|
||||
var macro_count = parseInt($("#hidden-module_macro_count").val());
|
||||
var delete_icon = '<?php html_print_image ("images/cross.png", false) ?>';
|
||||
|
||||
// Add inputs for the new macro
|
||||
$("#module_macros").append('<tr id="module_macros-' + macro_count + '" class="datos2"><td style=" font-weight: bold; vertical-align: top;" class="datos2">Name</td> \
|
||||
<td style="" class="datos2"><input type="text" name="module_macro_names[]" value="" id="text-module_macro_names[]" size="50" maxlength="60"></td> \
|
||||
<td style="font-weight: bold; vertical-align: top;" class="datos2">Value</td> \
|
||||
<td style="" class="datos2"><input type="text" name="module_macro_values[]" value="" id="text-module_macro_values[]" size="50" maxlength="60"></td> \
|
||||
<td style="" class="datos2"><a href="javascript: delete_macro(' + macro_count + ');">' + delete_icon + '</a></td></tr>');
|
||||
|
||||
// Update the macro count
|
||||
$("#hidden-module_macro_count").val(macro_count + 1);
|
||||
}
|
||||
|
||||
// Delete an existing module macro
|
||||
function delete_macro (num) {
|
||||
if ($("#module_macros-" + num).length) {
|
||||
$("#module_macros-" + num).remove();
|
||||
}
|
||||
|
||||
// Do not decrease the macro counter or new macros may overlap existing ones!
|
||||
}
|
||||
|
@ -4186,4 +4186,106 @@ div#footer_help{
|
||||
|
||||
.graph_conteiner_inside > div > .nodata_container{
|
||||
background-size: 120px 80px !important;
|
||||
}
|
||||
|
||||
#mssg_error_div{
|
||||
color: red;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
/*
|
||||
* View WUX
|
||||
*/
|
||||
|
||||
.wux_global_result_container{
|
||||
width: 100%;
|
||||
margin-top: 30px;
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.wux_global_result_title{
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
color:white;
|
||||
background-color: #373737;
|
||||
border: 1px solid #373737;
|
||||
height: 28px;
|
||||
}
|
||||
|
||||
.wux_global_result_title p {
|
||||
margin: 8px;
|
||||
}
|
||||
|
||||
.wux_global_result_content{
|
||||
width: 100%;
|
||||
border: 1px solid #e2e2e2;
|
||||
height: 120px;
|
||||
}
|
||||
|
||||
.wux_global_result_content_left{
|
||||
float:left;
|
||||
width: 40%;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.wux_global_result_content_left ul{
|
||||
display: inline-flex;
|
||||
margin-top: 15px;
|
||||
}
|
||||
|
||||
|
||||
.wux_global_result_content_left ul li p{
|
||||
margin-top: 35px;
|
||||
margin-right: 10px;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.wux_global_result_content_left ul li p b{
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.wux_global_result_content_right{
|
||||
float:right;
|
||||
width: 60%;
|
||||
}
|
||||
|
||||
.wux_global_result_content_right ul{
|
||||
display: inline-flex;
|
||||
margin-top: 15px;
|
||||
margin-left:100px;
|
||||
}
|
||||
|
||||
.wux_global_result_content_right ul li p{
|
||||
margin-top: 36px;
|
||||
margin-right: 10px;
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.wux_global_result_content_right ul li p b{
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.wux_transaction_container{
|
||||
width: 100%;
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
|
||||
.wux_result_transaction{
|
||||
width: 33%;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.wux_transaction_graphs{
|
||||
width: 33%;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.wux_transaction_graphs_pie{
|
||||
width: 33%;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.pagination_show_more{
|
||||
text-align: center;
|
||||
margin-top: 10px;
|
||||
}
|
@ -2837,14 +2837,6 @@ div#agent_wizard_subtabs {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
#code_license_dialog a:hover {
|
||||
color:red;
|
||||
}
|
||||
|
||||
#code_license_dialog *{
|
||||
color: #222222;
|
||||
}
|
||||
|
||||
/* GRAPHS CSS */
|
||||
|
||||
.parent_graph {
|
||||
|
@ -63,9 +63,7 @@ class User {
|
||||
$user = $system->getRequest('user', null);
|
||||
$password = $system->getRequest('password', null);
|
||||
|
||||
$nick = $system->safeInput($user);
|
||||
$pass = $system->safeInput($password);
|
||||
$this->login($nick, $pass);
|
||||
$this->login($user, $password);
|
||||
}
|
||||
|
||||
return $this->logged;
|
||||
@ -78,7 +76,6 @@ class User {
|
||||
$user = $system->getRequest('user', null);
|
||||
$user = $system->safeInput($user);
|
||||
$password = $system->getRequest('password', null);
|
||||
$password = $system->safeInput($password);
|
||||
}
|
||||
|
||||
if (!empty($user) && !empty($password)) {
|
||||
|
@ -102,7 +102,34 @@ if (is_ajax ()) {
|
||||
echo json_encode (false);
|
||||
return;
|
||||
}
|
||||
echo json_encode (modules_get_last_value ($id_module));
|
||||
|
||||
$module_value = modules_get_last_value ($id_module);
|
||||
if (is_numeric($row['value']) && !modules_is_string_type($module['id_tipo_modulo'])){
|
||||
$value = $module_value;
|
||||
}
|
||||
else{
|
||||
// If carriage returns present... then is a "Snapshot" data (full command output)
|
||||
$is_snapshot = is_snapshot_data ( $module_value );
|
||||
|
||||
$module = modules_get_agentmodule($id_module);
|
||||
|
||||
if (($config['command_snapshot']) && ($is_snapshot)){
|
||||
$handle = "snapshot"."_".$module["id_agente_modulo"];
|
||||
$url = 'include/procesos.php?agente='.$module["id_agente_modulo"];
|
||||
$win_handle = dechex(crc32($handle));
|
||||
|
||||
$link ="winopeng_var('operation/agentes/snapshot_view.php?id=".$module["id_agente_modulo"]."&refr=".$module["current_interval"]."&label=".$module["nombre"]."','".$win_handle."', 700,480)";
|
||||
|
||||
$value = '<a href="javascript:'.$link.'">' . html_print_image("images/default_list.png", true, array("border" => '0', "alt" => "", "title" => __("Snapshot view"))) . '</a> ';
|
||||
}
|
||||
else {
|
||||
$value = ui_print_module_string_value(
|
||||
$module_value, $module["id_agente_modulo"],
|
||||
$module["current_interval"], $module["module_name"]);
|
||||
}
|
||||
}
|
||||
|
||||
echo json_encode ($value);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -69,7 +69,7 @@ $label = get_parameter ("label");
|
||||
echo "</h2>";
|
||||
$datos = io_safe_output($row["datos"]);
|
||||
if (is_image_data($datos)) {
|
||||
echo '<center><img src="' . $datos . '" alt="image"/></center>';
|
||||
echo '<center><img src="' . $datos . '" alt="image" style="width:100%"/></center>';
|
||||
}
|
||||
else {
|
||||
$datos = preg_replace ('/</', '<', $datos);
|
||||
|
@ -1047,6 +1047,13 @@ $ux_console_tab = enterprise_hook('ux_console_tab');
|
||||
if ($ux_console_tab == -1)
|
||||
$ux_console_tab = "";
|
||||
|
||||
/* WUX Console */
|
||||
$modules_wux = enterprise_hook('get_wux_modules' , array($id_agente));
|
||||
if($modules_wux){
|
||||
$wux_console_tab = enterprise_hook('wux_console_tab');
|
||||
if ($wux_console_tab == -1)
|
||||
$wux_console_tab = "";
|
||||
}
|
||||
|
||||
/* GIS tab */
|
||||
$gistab="";
|
||||
@ -1178,7 +1185,8 @@ $onheader = array('manage' => $managetab,
|
||||
'custom' => $custom_fields,
|
||||
'graphs' => $graphs,
|
||||
'policy' => $policyTab,
|
||||
'ux_console' => $ux_console_tab);
|
||||
'ux_console' => $ux_console_tab,
|
||||
'wux_console' => $wux_console_tab);
|
||||
|
||||
//Added after it exists
|
||||
// If the agent has incidents associated
|
||||
@ -1250,8 +1258,15 @@ foreach ($config['extensions'] as $extension) {
|
||||
}
|
||||
}
|
||||
|
||||
if($tab == "wux_console_tab"){
|
||||
$help_header = "wux_console";
|
||||
}
|
||||
else{
|
||||
$help_header = "";
|
||||
}
|
||||
|
||||
ui_print_page_header(agents_get_alias($id_agente), $icon, false,
|
||||
"", false, $onheader, false, '', $config['item_title_size_text']);
|
||||
$help_header, false, $onheader, false, '', $config['item_title_size_text']);
|
||||
|
||||
|
||||
switch ($tab) {
|
||||
@ -1291,6 +1306,9 @@ switch ($tab) {
|
||||
case "ux_console_tab":
|
||||
enterprise_include ("operation/agentes/ux_console_view.php");
|
||||
break;
|
||||
case "wux_console_tab":
|
||||
enterprise_include ("operation/agentes/wux_console_view.php");
|
||||
break;
|
||||
case "graphs";
|
||||
require("operation/agentes/graphs.php");
|
||||
break;
|
||||
|
@ -9,7 +9,7 @@
|
||||
# This code is licensed under GPL 2.0 license.
|
||||
# **********************************************************************
|
||||
|
||||
PI_VERSION="7.0NG.711"
|
||||
PI_VERSION="7.0NG.710"
|
||||
FORCE=0
|
||||
DESTDIR=""
|
||||
LOG_TIMESTAMP=`date +"%Y/%m/%d %H:%M:%S"`
|
||||
|
@ -67,7 +67,7 @@ CREATE TABLE IF NOT EXISTS `tagente` (
|
||||
`custom_id` varchar(255) default '',
|
||||
`server_name` varchar(100) default '',
|
||||
`cascade_protection` tinyint(2) NOT NULL default '0',
|
||||
`cascade_protection_module` int(10) unsigned NOT NULL default '0',
|
||||
`cascade_protection_module` tinyint(2) NOT NULL default '0',
|
||||
`timezone_offset` TINYINT(2) NULL DEFAULT '0' COMMENT 'nuber of hours of diference with the server timezone' ,
|
||||
`icon_path` VARCHAR(127) NULL DEFAULT NULL COMMENT 'path in the server to the image of the icon representing the agent' ,
|
||||
`update_gis_data` TINYINT(1) NOT NULL DEFAULT '1' COMMENT 'set it to one to update the position data (altitude, longitude, latitude) when getting information from the agent or to 0 to keep the last value and do not update it' ,
|
||||
@ -118,7 +118,7 @@ CREATE TABLE IF NOT EXISTS `tagente_datos_inc` (
|
||||
-- ---------------------------------------------------------------------
|
||||
CREATE TABLE IF NOT EXISTS `tagente_datos_string` (
|
||||
`id_agente_modulo` int(10) unsigned NOT NULL default '0',
|
||||
`datos` text NOT NULL,
|
||||
`datos` mediumtext NOT NULL,
|
||||
`utimestamp` int(20) unsigned NOT NULL default 0,
|
||||
KEY `data_string_index_1` (`id_agente_modulo`),
|
||||
KEY `idx_utimestamp` USING BTREE (`utimestamp`)
|
||||
@ -146,7 +146,7 @@ CREATE TABLE IF NOT EXISTS `tagente_datos_log4x` (
|
||||
CREATE TABLE IF NOT EXISTS `tagente_estado` (
|
||||
`id_agente_estado` int(10) unsigned NOT NULL auto_increment,
|
||||
`id_agente_modulo` int(10) NOT NULL default '0',
|
||||
`datos` text NOT NULL,
|
||||
`datos` mediumtext NOT NULL,
|
||||
`timestamp` datetime NOT NULL default '1970-01-01 00:00:00',
|
||||
`estado` int(4) NOT NULL default '0',
|
||||
`known_status` tinyint(4) default 0,
|
||||
|
@ -112,7 +112,7 @@ INSERT INTO `tconfig` (`token`, `value`) VALUES
|
||||
('MR', 4),
|
||||
('identification_reminder', 1),
|
||||
('identification_reminder_timestamp', 0),
|
||||
('current_package_enterprise', '711'),
|
||||
('current_package_enterprise', '710'),
|
||||
('post_process_custom_values', '{"0.00000038580247":"Seconds to months","0.00000165343915":"Seconds to weeks","0.00001157407407":"Seconds to days","0.01666666666667":"Seconds to minutes","0.00000000093132":"Bytes to Gigabytes","0.00000095367432":"Bytes to Megabytes","0.0009765625":"Bytes to Kilobytes","0.00000001653439":"Timeticks to weeks","0.00000011574074":"Timeticks to days"}');
|
||||
|
||||
UNLOCK TABLES;
|
||||
@ -263,6 +263,7 @@ INSERT INTO `ttipo_modulo` VALUES
|
||||
(22,'async_data', 6, 'Asyncronous numeric data', 'mod_async_data.png'),
|
||||
(23,'async_string', 8, 'Asyncronous string data', 'mod_async_string.png'),
|
||||
(24,'log4x',0,'Log4x','mod_log4x.png'),
|
||||
(25,'web_analysis', 8, 'Web analysis data', 'module-wux.png'),
|
||||
(30,'web_data',9,'Remote HTTP module to check latency','mod_web_data.png'),
|
||||
(31,'web_proc',9,'Remote HTTP module to check server response','mod_web_proc.png'),
|
||||
(32,'web_content_data',9,'Remote HTTP module to retrieve numeric data','mod_web_data.png'),
|
||||
@ -344,6 +345,7 @@ INSERT INTO tmodule VALUES (4,'Plugin module');
|
||||
INSERT INTO tmodule VALUES (5,'Prediction module');
|
||||
INSERT INTO tmodule VALUES (6,'WMI module');
|
||||
INSERT INTO tmodule VALUES (7, 'Web module');
|
||||
INSERT INTO tmodule VALUES (8, 'Wux module');
|
||||
|
||||
INSERT INTO `tnetwork_component` (`id_nc`, `name`, `description`, `id_group`, `type`, `max`, `min`, `module_interval`, `tcp_port`, `tcp_send`, `tcp_rcv`, `snmp_community`, `snmp_oid`, `id_module_group`, `id_modulo`, `id_plugin`, `plugin_user`, `plugin_pass`, `plugin_parameter`, `max_timeout`, `history_data`, `min_warning`, `max_warning`, `str_warning`, `min_critical`, `max_critical`, `str_critical`, `min_ff_event`, `custom_string_1`, `custom_string_2`, `custom_string_3`, `custom_integer_1`, `custom_integer_2`, `post_process`, `wizard_level`, `critical_instructions`, `warning_instructions`, `unknown_instructions`, `tags`, `disabled_types_event`, `module_macros`) VALUES (1,'OS Total process','Total process in Operating System (UNIX MIB)',13,15,0,0,300,0,'','','public','HOST-RESOURCES-MIB::hrSystemProcesses.0 ',4,2,0,NULL,NULL,NULL,0,1,0.00,0.00,NULL,0.00,0.00,NULL,0,NULL,NULL,NULL,0,0,0.0000000000000,'basic','','','','','','');
|
||||
INSERT INTO `tnetwork_component` (`id_nc`, `name`, `description`, `id_group`, `type`, `max`, `min`, `module_interval`, `tcp_port`, `tcp_send`, `tcp_rcv`, `snmp_community`, `snmp_oid`, `id_module_group`, `id_modulo`, `id_plugin`, `plugin_user`, `plugin_pass`, `plugin_parameter`, `max_timeout`, `history_data`, `min_warning`, `max_warning`, `str_warning`, `min_critical`, `max_critical`, `str_critical`, `min_ff_event`, `custom_string_1`, `custom_string_2`, `custom_string_3`, `custom_integer_1`, `custom_integer_2`, `post_process`, `wizard_level`, `critical_instructions`, `warning_instructions`, `unknown_instructions`, `tags`, `disabled_types_event`, `module_macros`) VALUES (2,'OS CPU Load (1 min)','CPU Load in Operating System (UNIX MIB)',13,15,0,0,300,0,'','','public','UCD-SNMP-MIB::laLoad.1',4,2,0,NULL,NULL,NULL,0,1,0.00,0.00,NULL,0.00,0.00,NULL,0,NULL,NULL,NULL,0,0,0.0000000000000,'basic','','','','','','');
|
||||
|
@ -1,7 +1,7 @@
|
||||
#############################################################################
|
||||
# Pandora FMS Server Parameters
|
||||
# Pandora FMS, the Flexible Monitoring System.
|
||||
# Version 7.0NG.711
|
||||
# Version 7.0NG.710
|
||||
# Licensed under GPL license v2,
|
||||
# (c) 2003-2016 Artica Soluciones Tecnologicas
|
||||
# http://www.pandorafms.com
|
||||
@ -560,3 +560,12 @@ enc_dir /usr/share/pandora_server/enc/
|
||||
# Go to http://wiki.pandorafms.com/ for more information.
|
||||
dynamic_updates 5
|
||||
|
||||
# Enable (1) or disable (0) the Pandora FMS WUX Server (PANDORA FMS ENTERPRISE ONLY).
|
||||
wuxserver 0
|
||||
|
||||
# Host of the Selenium Grid Server.
|
||||
#wux_host localhost
|
||||
|
||||
# Port of the Selenium Grid Server.
|
||||
#wux_port 4444
|
||||
|
||||
|
@ -445,6 +445,11 @@ sub pandora_load_config {
|
||||
$pa_config->{"warmup_unknown_interval"} = 300; # 6.1
|
||||
$pa_config->{"warmup_unknown_on"} = 1; # 6.1
|
||||
|
||||
$pa_config->{"wuxserver"} = 1; # 7.0
|
||||
$pa_config->{"wux_host"} = undef; # 7.0
|
||||
$pa_config->{"wux_port"} = 4444; # 7.0
|
||||
$pa_config->{"wux_browser"} = "*firefox"; # 7.0
|
||||
|
||||
#$pa_config->{'include_agents'} = 0; #6.1
|
||||
#
|
||||
# External .enc files for XML::Parser.
|
||||
@ -1030,6 +1035,18 @@ sub pandora_load_config {
|
||||
elsif ($parametro =~ m/^dynamic_constant\s+([0-9]*)/i) {
|
||||
$pa_config->{'dynamic_constant'}= clean_blank($1);
|
||||
}
|
||||
elsif ($parametro =~ m/^wuxserver\s+([0-1]*)/i) {
|
||||
$pa_config->{"wuxserver"} = clean_blank($1);
|
||||
}
|
||||
elsif ($parametro =~ m/^wux_host\s+(.*)/i) {
|
||||
$pa_config->{'wux_host'}= clean_blank($1);
|
||||
}
|
||||
elsif ($parametro =~ m/^wux_port\s+([0-9]*)/i) {
|
||||
$pa_config->{'wux_port'}= clean_blank($1);
|
||||
}
|
||||
elsif ($parametro =~ m/^wux_browser\s+(.*)/i) {
|
||||
$pa_config->{'wux_browser'}= clean_blank($1);
|
||||
}
|
||||
} # end of loop for parameter #
|
||||
|
||||
# Set to RDBMS' standard port
|
||||
|
@ -243,7 +243,7 @@ our @EXPORT = qw(
|
||||
|
||||
# Some global variables
|
||||
our @DayNames = qw(sunday monday tuesday wednesday thursday friday saturday);
|
||||
our @ServerTypes = qw (dataserver networkserver snmpconsole reconserver pluginserver predictionserver wmiserver exportserver inventoryserver webserver eventserver icmpserver snmpserver satelliteserver transactionalserver mfserver syncserver);
|
||||
our @ServerTypes = qw (dataserver networkserver snmpconsole reconserver pluginserver predictionserver wmiserver exportserver inventoryserver webserver eventserver icmpserver snmpserver satelliteserver transactionalserver mfserver syncserver wuxserver);
|
||||
our @AlertStatus = ('Execute the alert', 'Do not execute the alert', 'Do not execute the alert, but increment its internal counter', 'Cease the alert', 'Recover the alert', 'Reset internal counter');
|
||||
|
||||
# Event storm protection (no alerts or events)
|
||||
@ -1010,8 +1010,7 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
_modulestatus_ => undef,
|
||||
_moduletags_ => undef,
|
||||
'_moduledata_\S+_' => undef,
|
||||
_id_agent_ => (defined ($module)) ? $module->{'id_agente'} : '',
|
||||
_id_module_ => (defined ($module)) ? $module->{'id_agente_modulo'} : '',
|
||||
_id_agent_ => (defined ($module)) ? $module->{'id_agente'} : '',
|
||||
_id_group_ => (defined ($group)) ? $group->{'id_grupo'} : '',
|
||||
_id_alert_ => (defined ($alert->{'id_template_module'})) ? $alert->{'id_template_module'} : '',
|
||||
_interval_ => (defined ($module) && $module->{'module_interval'} != 0) ? $module->{'module_interval'} : (defined ($agent)) ? $agent->{'intervalo'} : '',
|
||||
@ -1088,6 +1087,21 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
|
||||
# Email
|
||||
} elsif ($clean_name eq "eMail") {
|
||||
|
||||
my $attach_data_as_image = 0;
|
||||
|
||||
my $cid_data = "CID_IMAGE";
|
||||
my $dataname = "CID_IMAGE.png";
|
||||
|
||||
if ($data =~ /^data:image\/png;base64, /) {
|
||||
# macro _data_ substitution in case is image.
|
||||
$attach_data_as_image = 1;
|
||||
my $_cid = '<img style="height: 150px;" src="cid:' . $cid_data . '"/>';
|
||||
|
||||
$field3 =~ s/_data_/$_cid/g;
|
||||
}
|
||||
|
||||
|
||||
# Address
|
||||
$field1 = subst_alert_macros ($field1, \%macros, $pa_config, $dbh, $agent, $module);
|
||||
# Subject
|
||||
@ -1095,10 +1109,9 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
# Message
|
||||
$field3 = subst_alert_macros ($field3, \%macros, $pa_config, $dbh, $agent, $module);
|
||||
|
||||
# Check for _module_graph_Xh_ macros and _module_graphth_Xh_
|
||||
# Check for _module_graph_Xh_ macros
|
||||
my $module_graph_list = {};
|
||||
my $macro_regexp = "_modulegraph_(\\d+)h_";
|
||||
my $macro_regexp2 = "_modulegraphth_(\\d+)h_";
|
||||
|
||||
# API connection
|
||||
my $ua = new LWP::UserAgent;
|
||||
@ -1114,14 +1127,8 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
|
||||
my $subst_func = sub {
|
||||
my $hours = shift;
|
||||
my $threshold = shift;
|
||||
my $period = $hours * 3600; # Hours to seconds
|
||||
if($threshold == 0){
|
||||
$params->{"other"} = $period . '%7C0%7C0';
|
||||
}
|
||||
else{
|
||||
$params->{"other"} = $period . '%7C0%7C1';
|
||||
}
|
||||
$params->{"other"} = $period . '%7C0';
|
||||
$params->{"other_mode"} = 'url_encode_separator_%7C';
|
||||
my $cid = 'module_graph_' . $hours . 'h';
|
||||
|
||||
@ -1135,16 +1142,15 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
return '<img src="cid:'.$cid.'">';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return '';
|
||||
};
|
||||
|
||||
|
||||
# Macro data may contain HTML entities
|
||||
eval {
|
||||
no warnings;
|
||||
local $SIG{__DIE__};
|
||||
$field3 =~ s/$macro_regexp/$subst_func->($1, 0)/ige;
|
||||
$field3 =~ s/$macro_regexp2/$subst_func->($1, 1)/ige;
|
||||
$field3 =~ s/$macro_regexp/$subst_func->($1)/ige;
|
||||
};
|
||||
|
||||
# Default content type
|
||||
@ -1157,10 +1163,14 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
$content_type = 'text/html; charset="UTF-8"';
|
||||
}
|
||||
|
||||
|
||||
my $boundary = "====" . time() . "====";
|
||||
my $html_content_type = $content_type;
|
||||
|
||||
# Build the mail with attached content
|
||||
if (keys(%{$module_graph_list}) > 0) {
|
||||
my $boundary = "====" . time() . "====";
|
||||
my $html_content_type = $content_type;
|
||||
if ((keys(%{$module_graph_list}) > 0) && ($attach_data_as_image == 0)) {
|
||||
# module_graph only available if data is NOT an image
|
||||
|
||||
$content_type = 'multipart/related; boundary="'.$boundary.'"';
|
||||
$boundary = "--" . $boundary;
|
||||
|
||||
@ -1187,6 +1197,28 @@ sub pandora_execute_action ($$$$$$$$$;$) {
|
||||
|
||||
$field3 .= $boundary . "--\n";
|
||||
}
|
||||
|
||||
if ($attach_data_as_image == 1) {
|
||||
# it's an image in base64!
|
||||
|
||||
$content_type = 'multipart/related; boundary="'.$boundary.'"';
|
||||
$boundary = "--" . $boundary;
|
||||
|
||||
my $base64_data = substr($data, 23); # remove first 23 characters: 'data:image/png;base64, '
|
||||
|
||||
$field3 = $boundary . "\n"
|
||||
. "Content-Type: " . $html_content_type . "\n\n"
|
||||
#. "Content-Transfer-Encoding: quoted-printable\n\n"
|
||||
. $field3 . "\n";
|
||||
|
||||
$field3 .= $boundary . "\n"
|
||||
. "Content-Type: image/png; name=\"" . $dataname . "\"\n"
|
||||
. "Content-Disposition: inline; filename=\"" . $dataname . "\"\n"
|
||||
. "Content-Transfer-Encoding: base64\n"
|
||||
. "Content-ID: <" . $cid_data . ">\n"
|
||||
. "Content-Location: " . $dataname . "\n\n"
|
||||
. $base64_data . "\n";
|
||||
}
|
||||
|
||||
if ($pa_config->{"mail_in_separate"} != 0){
|
||||
foreach my $address (split (',', $field1)) {
|
||||
|
@ -61,6 +61,7 @@ our @EXPORT = qw(
|
||||
TRANSACTIONALSERVER
|
||||
SYNCSERVER
|
||||
METACONSOLE_LICENSE
|
||||
WUXSERVER
|
||||
$DEVNULL
|
||||
$OS
|
||||
$OS_VERSION
|
||||
@ -122,6 +123,7 @@ use constant SATELLITESERVER => 13;
|
||||
use constant TRANSACTIONALSERVER => 14;
|
||||
use constant MFSERVER => 15;
|
||||
use constant SYNCSERVER => 16;
|
||||
use constant WUXSERVER => 17;
|
||||
|
||||
# Value for a metaconsole license type
|
||||
use constant METACONSOLE_LICENSE => 0x01;
|
||||
|