2011-09-12 Vanessa Gil <vanessa.gil@artica.es>
* pandora_server/util/pandora_manage.pl: Applied Kosaka's patch to store data in DB with encoding in HTML entities. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4939 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
bd250bfc78
commit
1dcc5481eb
|
@ -1,3 +1,9 @@
|
|||
2011-09-12 Vanessa Gil <vanessa.gil@artica.es>
|
||||
|
||||
* pandora_server/util/pandora_manage.pl: Applied Kosaka's patch to store
|
||||
data in DB with encoding in HTML entities.
|
||||
|
||||
|
||||
2011-09-12 Dario Rodriguez <dario.rodriguez@artica.es>
|
||||
|
||||
* util/recon_scripts/snmpdevices.pl: Fixed some problems with the script.
|
||||
|
|
|
@ -537,7 +537,7 @@ sub pandora_manage_main ($$$) {
|
|||
print "[INFO] Creating agent '$agent_name'\n\n";
|
||||
|
||||
$address = '' unless defined ($address);
|
||||
$description = '' unless defined ($description);
|
||||
$description = (defined ($description) ? safe_input($description) : '' ); # safe_input() might be better at pandora_create_agent() (when passing 'description' to db_insert())
|
||||
$interval = 300 unless defined ($interval);
|
||||
|
||||
my $id_group = get_group_id($dbh,$group_name);
|
||||
|
@ -631,7 +631,7 @@ sub pandora_manage_main ($$$) {
|
|||
my %parameters;
|
||||
|
||||
$parameters{'id_tipo_modulo'} = $module_type_id;
|
||||
$parameters{'nombre'} = $module_name;
|
||||
$parameters{'nombre'} = safe_input($module_name);
|
||||
$parameters{'id_agente'} = $agent_id;
|
||||
|
||||
# Optional parameters
|
||||
|
@ -641,7 +641,7 @@ sub pandora_manage_main ($$$) {
|
|||
$parameters{'min_critical'} = $critical_min unless !defined ($critical_min);
|
||||
$parameters{'max_critical'} = $critical_max unless !defined ($critical_max);
|
||||
$parameters{'history_data'} = $history_data unless !defined ($history_data);
|
||||
$parameters{'descripcion'} = $description unless !defined ($description);
|
||||
$parameters{'descripcion'} = safe_input($description) unless !defined ($description);
|
||||
$parameters{'min'} = $min unless !defined ($min);
|
||||
$parameters{'max'} = $max unless !defined ($max);
|
||||
$parameters{'post_process'} = $post_process unless !defined ($post_process);
|
||||
|
@ -698,7 +698,7 @@ sub pandora_manage_main ($$$) {
|
|||
my %parameters;
|
||||
|
||||
$parameters{'id_tipo_modulo'} = $module_type_id;
|
||||
$parameters{'nombre'} = $module_name;
|
||||
$parameters{'nombre'} = safe_input($module_name);
|
||||
$parameters{'id_agente'} = $agent_id;
|
||||
$parameters{'ip_target'} = $module_address;
|
||||
|
||||
|
@ -710,7 +710,7 @@ sub pandora_manage_main ($$$) {
|
|||
$parameters{'max_critical'} = $critical_max unless !defined ($critical_max);
|
||||
$parameters{'history_data'} = $history_data unless !defined ($history_data);
|
||||
$parameters{'tcp_port'} = $module_port unless !defined ($module_port);
|
||||
$parameters{'descripcion'} = $description unless !defined ($description);
|
||||
$parameters{'descripcion'} = safe_input($description) unless !defined ($description);
|
||||
$parameters{'min'} = $min unless !defined ($min);
|
||||
$parameters{'max'} = $max unless !defined ($max);
|
||||
$parameters{'post_process'} = $post_process unless !defined ($post_process);
|
||||
|
@ -756,7 +756,7 @@ sub pandora_manage_main ($$$) {
|
|||
my %parameters;
|
||||
|
||||
$parameters{'id_tipo_modulo'} = $module_type_id;
|
||||
$parameters{'nombre'} = $module_name;
|
||||
$parameters{'nombre'} = safe_input($module_name);
|
||||
$parameters{'id_agente'} = $agent_id;
|
||||
$parameters{'ip_target'} = $module_address;
|
||||
$parameters{'tcp_port'} = $module_port;
|
||||
|
@ -769,7 +769,7 @@ sub pandora_manage_main ($$$) {
|
|||
$parameters{'min_critical'} = $critical_min unless !defined ($critical_min);
|
||||
$parameters{'max_critical'} = $critical_max unless !defined ($critical_max);
|
||||
$parameters{'history_data'} = $history_data unless !defined ($history_data);
|
||||
$parameters{'descripcion'} = $description unless !defined ($description);
|
||||
$parameters{'descripcion'} = safe_input($description) unless !defined ($description);
|
||||
$parameters{'min'} = $min unless !defined ($min);
|
||||
$parameters{'max'} = $max unless !defined ($max);
|
||||
$parameters{'post_process'} = $post_process unless !defined ($post_process);
|
||||
|
@ -830,7 +830,7 @@ sub pandora_manage_main ($$$) {
|
|||
my %parameters;
|
||||
|
||||
$parameters{'id_tipo_modulo'} = $module_type_id;
|
||||
$parameters{'nombre'} = $module_name;
|
||||
$parameters{'nombre'} = safe_input($module_name);
|
||||
$parameters{'id_agente'} = $agent_id;
|
||||
$parameters{'ip_target'} = $module_address;
|
||||
$parameters{'tcp_port'} = $module_port;
|
||||
|
@ -846,7 +846,7 @@ sub pandora_manage_main ($$$) {
|
|||
$parameters{'min_critical'} = $critical_min unless !defined ($critical_min);
|
||||
$parameters{'max_critical'} = $critical_max unless !defined ($critical_max);
|
||||
$parameters{'history_data'} = $history_data unless !defined ($history_data);
|
||||
$parameters{'descripcion'} = $description unless !defined ($description);
|
||||
$parameters{'descripcion'} = safe_input($description) unless !defined ($description);
|
||||
$parameters{'min'} = $min unless !defined ($min);
|
||||
$parameters{'max'} = $max unless !defined ($max);
|
||||
$parameters{'post_process'} = $post_process unless !defined ($post_process);
|
||||
|
@ -1019,7 +1019,7 @@ sub pandora_manage_main ($$$) {
|
|||
param_check($ltotal, 4, 1);
|
||||
my ($user_name,$password,$is_admin,$comments) = @ARGV[2..5];
|
||||
|
||||
$comments = '' unless defined ($comments);
|
||||
$comments = (defined ($comments) ? safe_input($comments) : '' );
|
||||
|
||||
print "[INFO] Creating user '$user_name'\n\n";
|
||||
|
||||
|
|
Loading…
Reference in New Issue