Skip to content
Snippets Groups Projects
Commit 907443f1 authored by Tomáš Plesník's avatar Tomáš Plesník
Browse files

opravena zamena attack_scale pri kontrole timeoutu; doplnena kontrola definice...

opravena zamena attack_scale pri kontrole timeoutu; doplnena kontrola definice polozky udalosti; predelano generovani hlasky zmenenych polozek udalosti serverem
parent 08c8d528
No related branches found
No related tags found
No related merge requests found
......@@ -240,36 +240,25 @@ sub saveNewEvent
"Unknown detected time format: '$detected'");
}
my $change_string = "";
if ($target_port !~ /^\d+\z/) {
$change_string = $change_string . "target_port: '$target_port'";
my @change_list;
if (defined $target_port && $target_port !~ /^\d+\z/) {
push(@change_list, "target_port: '$target_port'");
$target_port = undef;
}
if ($attack_scale !~ /^\d+\z/) {
if ($change_string eq "") {
$change_string = $change_string . "attack_scale: '$attack_scale'";
} else {
$change_string = $change_string . ", attack_scale: '$attack_scale'";
}
if (defined $attack_scale && $attack_scale !~ /^\d+\z/) {
push(@change_list, "attack_scale: '$attack_scale'");
$attack_scale = undef;
}
if ($priority !~ /^\d+\z/) {
if ($change_string eq "") {
$change_string = $change_string . "priority: '$priority'";
} else {
$change_string = $change_string . ", priority: '$priority'";
}
if (defined $priority && $priority !~ /^\d+\z/) {
push(@change_list, "priority: '$priority'");
$priority = undef;
}
if ($timeout !~ /^\d+\z/) {
if ($change_string eq "") {
$change_string = $change_string . "attack_scale: '$timeout'";
} else {
$change_string = $change_string . ", attack_scale: '$timeout'";
}
if (defined $timeout && $timeout !~ /^\d+\z/) {
push(@change_list, "timeout: '$timeout'");
$timeout = undef;
}
if ($change_string ne ""){
my $change_string = join(", ", @change_list);
if ($change_string ne "") {
sendMsg("info",
"Unknown event items detected {originaly - $change_string} received in $received from [IP '$ip'; CN(AN): $alt_names; Service: '$service'; Type: '$type'; Detected: $detected]",
undef);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment