Merge branch 'develop' into ent-5935-Logs-de-la-consola-refactorizacion

This commit is contained in:
alejandro-campos 2020-06-19 12:22:28 +02:00
commit d64ff918d6
33 changed files with 173 additions and 57 deletions

View File

@ -1,5 +1,5 @@
package: pandorafms-agent-unix package: pandorafms-agent-unix
Version: 7.0NG.746-200617 Version: 7.0NG.746-200619
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.746-200617" pandora_version="7.0NG.746-200619"
echo "Test if you has the tools for to make the packages." echo "Test if you has the tools for to make the packages."
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null

View File

@ -55,7 +55,7 @@ my $Sem = undef;
my $ThreadSem = undef; my $ThreadSem = undef;
use constant AGENT_VERSION => '7.0NG.746'; use constant AGENT_VERSION => '7.0NG.746';
use constant AGENT_BUILD => '200617'; use constant AGENT_BUILD => '200619';
# Agent log default file size maximum and instances # Agent log default file size maximum and instances
use constant DEFAULT_MAX_LOG_SIZE => 600000; use constant DEFAULT_MAX_LOG_SIZE => 600000;

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_agent_unix %define name pandorafms_agent_unix
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
Summary: Pandora FMS Linux agent, PERL version Summary: Pandora FMS Linux agent, PERL version
Name: %{name} Name: %{name}

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_agent_unix %define name pandorafms_agent_unix
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
Summary: Pandora FMS Linux agent, PERL version Summary: Pandora FMS Linux agent, PERL version
Name: %{name} Name: %{name}

View File

@ -10,7 +10,7 @@
# ********************************************************************** # **********************************************************************
PI_VERSION="7.0NG.746" PI_VERSION="7.0NG.746"
PI_BUILD="200617" PI_BUILD="200619"
OS_NAME=`uname -s` OS_NAME=`uname -s`
FORCE=0 FORCE=0

View File

@ -186,7 +186,7 @@ UpgradeApplicationID
{} {}
Version Version
{200617} {200619}
ViewReadme ViewReadme
{Yes} {Yes}

View File

@ -30,7 +30,7 @@ using namespace Pandora;
using namespace Pandora_Strutils; using namespace Pandora_Strutils;
#define PATH_SIZE _MAX_PATH+1 #define PATH_SIZE _MAX_PATH+1
#define PANDORA_VERSION ("7.0NG.746(Build 200617)") #define PANDORA_VERSION ("7.0NG.746(Build 200619)")
string pandora_path; string pandora_path;
string pandora_dir; string pandora_dir;

View File

@ -11,7 +11,7 @@ BEGIN
VALUE "LegalCopyright", "Artica ST" VALUE "LegalCopyright", "Artica ST"
VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "OriginalFilename", "PandoraAgent.exe"
VALUE "ProductName", "Pandora FMS Windows Agent" VALUE "ProductName", "Pandora FMS Windows Agent"
VALUE "ProductVersion", "(7.0NG.746(Build 200617))" VALUE "ProductVersion", "(7.0NG.746(Build 200619))"
VALUE "FileVersion", "1.0.0.0" VALUE "FileVersion", "1.0.0.0"
END END
END END

View File

@ -1,5 +1,5 @@
package: pandorafms-console package: pandorafms-console
Version: 7.0NG.746-200617 Version: 7.0NG.746-200619
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.746-200617" pandora_version="7.0NG.746-200619"
package_pear=0 package_pear=0
package_pandora=1 package_pandora=1

View File

@ -43,7 +43,47 @@ if (empty($update_module_id)) {
$data = []; $data = [];
$data[0] = __('Target IP').' '.ui_print_help_icon('wmi_module_tab', true); $data[0] = __('Target IP').' '.ui_print_help_icon('wmi_module_tab', true);
$data[1] = html_print_input_text('ip_target', $ip_target, '', 15, 60, true);
if ($page == 'enterprise/godmode/policies/policy_modules') {
if ($ip_target != 'auto' && $ip_target != '') {
$custom_ip_target = $ip_target;
$ip_target = 'custom';
} else if ($ip_target == '') {
$ip_target = 'force_pri';
$custom_ip_target = '';
} else {
$custom_ip_target = '';
}
$target_ip_values = [];
$target_ip_values['auto'] = __('Auto');
$target_ip_values['force_pri'] = __('Force primary key');
$target_ip_values['custom'] = __('Custom');
$data[1] = html_print_select(
$target_ip_values,
'ip_target',
$ip_target,
'',
'',
'',
true,
false,
false,
'',
false,
'width:200px;'
);
$data[1] .= html_print_input_text('custom_ip_target', $custom_ip_target, '', 15, 60, true);
} else {
if ($ip_target == 'auto') {
$ip_target = agents_get_address($id_agente);
}
$data[1] = html_print_input_text('ip_target', $ip_target, '', 15, 60, true);
}
$data[2] = __('Namespace').ui_print_help_tip(__('Optional. WMI namespace. If unsure leave blank.'), true); $data[2] = __('Namespace').ui_print_help_tip(__('Optional. WMI namespace. If unsure leave blank.'), true);
$data[3] = html_print_input_text( $data[3] = html_print_input_text(
'tcp_send', 'tcp_send',
@ -136,3 +176,21 @@ $data[3] = html_print_input_text(
); );
push_table_simple($data, 'key_field'); push_table_simple($data, 'key_field');
?>
<script type="text/javascript">
$(document).ready (function () {
var custom_ip_target = "<?php echo $custom_ip_target; ?>";
if(custom_ip_target == ''){
$("#text-custom_ip_target").hide();
}
$('#ip_target').change(function() {
if($(this).val() == 'custom') {
$("#text-custom_ip_target").show();
}
else{
$("#text-custom_ip_target").hide();
}
});
});
</script>

View File

@ -471,7 +471,7 @@ foreach ($items as $item) {
if ($is_inventory_item) { if ($is_inventory_item) {
$external_source = json_decode($item['external_source'], true); $external_source = json_decode($item['external_source'], true);
$agents = $external_source['id_agents']; $agents = $external_source['id_agents'];
$modules = $external_source['inventory_modules']; $modules = io_safe_output($external_source['inventory_modules']);
$agent_name_db = []; $agent_name_db = [];
foreach ($agents as $a) { foreach ($agents as $a) {

View File

@ -629,6 +629,16 @@ class DiscoveryTaskList extends HTML
$data[6] .= __('Discovery.App.Oracle'); $data[6] .= __('Discovery.App.Oracle');
break; break;
case DISCOVERY_APP_DB2:
// Discovery Applications DB2.
$data[6] = html_print_image(
'images/network.png',
true,
['title' => __('Discovery Applications DB2')]
).'&nbsp;&nbsp;';
$data[6] .= __('Discovery.App.DB2');
break;
case DISCOVERY_DEPLOY_AGENTS: case DISCOVERY_DEPLOY_AGENTS:
// Internal deployment task. // Internal deployment task.
$no_operations = true; $no_operations = true;
@ -722,6 +732,8 @@ class DiscoveryTaskList extends HTML
if ($task['disabled'] != 2 && $task['utimestamp'] > 0 if ($task['disabled'] != 2 && $task['utimestamp'] > 0
&& $task['type'] != DISCOVERY_APP_MYSQL && $task['type'] != DISCOVERY_APP_MYSQL
&& $task['type'] != DISCOVERY_APP_ORACLE && $task['type'] != DISCOVERY_APP_ORACLE
&& $task['type'] != DISCOVERY_APP_DB2
&& $task['type'] != DISCOVERY_APP_SAP
&& $task['type'] != DISCOVERY_CLOUD_AWS_RDS && $task['type'] != DISCOVERY_CLOUD_AWS_RDS
) { ) {
if (check_acl($config['id_user'], 0, 'MR')) { if (check_acl($config['id_user'], 0, 'MR')) {
@ -879,6 +891,9 @@ class DiscoveryTaskList extends HTML
case DISCOVERY_APP_ORACLE: case DISCOVERY_APP_ORACLE:
return 'wiz=app&mode=oracle&page=0'; return 'wiz=app&mode=oracle&page=0';
case DISCOVERY_APP_DB2:
return 'wiz=app&mode=DB2&page=0';
case DISCOVERY_CLOUD_AWS: case DISCOVERY_CLOUD_AWS:
case DISCOVERY_CLOUD_AWS_EC2: case DISCOVERY_CLOUD_AWS_EC2:
return 'wiz=cloud&mode=amazonws&ki='.$task['auth_strings'].'&page=1'; return 'wiz=cloud&mode=amazonws&ki='.$task['auth_strings'].'&page=1';

View File

@ -85,7 +85,7 @@ function process_user_login($login, $pass, $api=false)
return process_user_login_local($login, $pass, $api); return process_user_login_local($login, $pass, $api);
} else { } else {
$login_remote = process_user_login_remote($login, io_safe_output($pass), $api); $login_remote = process_user_login_remote($login, io_safe_output($pass), $api);
if ($login_remote == false) { if ($login_remote == false && $config['fallback_local_auth']) {
return process_user_login_local($login, $pass, $api); return process_user_login_local($login, $pass, $api);
} else { } else {
return $login_remote; return $login_remote;
@ -258,27 +258,32 @@ function process_user_login_remote($login, $pass, $api=false)
return false; return false;
} }
if (($config['auth'] === 'ad') if (($config['auth'] === 'ad')) {
&& (isset($config['ad_advanced_config']) && $config['ad_advanced_config']) // Check if autocreate remote users is active.
) { if ($config['autocreate_remote_users'] == 1) {
$return = enterprise_hook( change_local_user_pass_ldap($login, $pass);
'prepare_permissions_groups_of_user_ad', }
[
$login,
$pass,
false,
true,
defined('METACONSOLE'),
]
);
if ($return === 'error_permissions') { if (isset($config['ad_advanced_config']) && $config['ad_advanced_config']) {
$config['auth_error'] = __('Problems with configuration permissions. Please contact with Administrator'); $return = enterprise_hook(
return false; 'prepare_permissions_groups_of_user_ad',
} else { [
if ($return === 'permissions_changed') { $login,
$config['auth_error'] = __('Your permissions have changed. Please, login again.'); $pass,
false,
true,
defined('METACONSOLE'),
]
);
if ($return === 'error_permissions') {
$config['auth_error'] = __('Problems with configuration permissions. Please contact with Administrator');
return false; return false;
} else {
if ($return === 'permissions_changed') {
$config['auth_error'] = __('Your permissions have changed. Please, login again.');
return false;
}
} }
} }
} else if ($config['auth'] === 'ldap') { } else if ($config['auth'] === 'ldap') {

View File

@ -20,7 +20,7 @@
/** /**
* Pandora build version and version * Pandora build version and version
*/ */
$build_version = 'PC200617'; $build_version = 'PC200619';
$pandora_version = 'v7.0NG.746'; $pandora_version = 'v7.0NG.746';
// Do not overwrite default timezone set if defined. // Do not overwrite default timezone set if defined.

View File

@ -601,6 +601,7 @@ define('DISCOVERY_CLOUD_AWS_RDS', 7);
define('DISCOVERY_CLOUD_AZURE_COMPUTE', 8); define('DISCOVERY_CLOUD_AZURE_COMPUTE', 8);
define('DISCOVERY_DEPLOY_AGENTS', 9); define('DISCOVERY_DEPLOY_AGENTS', 9);
define('DISCOVERY_APP_SAP', 10); define('DISCOVERY_APP_SAP', 10);
define('DISCOVERY_APP_DB2', 11);
// Force task build tmp results. // Force task build tmp results.

View File

@ -160,7 +160,7 @@ function reporting_make_reporting_data(
$return = []; $return = [];
if (!empty($report)) { if (!empty($report)) {
$contents = $report['contents']; $contents = io_safe_output($report['contents']);
} else { } else {
$report = io_safe_output(db_get_row('treport', 'id_report', $id_report)); $report = io_safe_output(db_get_row('treport', 'id_report', $id_report));
$contents = io_safe_output( $contents = io_safe_output(
@ -2236,7 +2236,7 @@ function reporting_inventory($report, $content, $type)
$es = json_decode($content['external_source'], true); $es = json_decode($content['external_source'], true);
$id_agent = $es['id_agents']; $id_agent = $es['id_agents'];
$module_name = $es['inventory_modules']; $module_name = io_safe_input($es['inventory_modules']);
if (empty($module_name)) { if (empty($module_name)) {
$module_name = [0 => 0]; $module_name = [0 => 0];
} }
@ -6147,7 +6147,13 @@ function reporting_advanced_sla(
$time_total += $time_interval; $time_total += $time_interval;
if ($time_interval > 0) { if ($time_interval > 0) {
$total_checks++; if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)
) {
$total_checks++;
}
if ((isset($current_data['datos'])) if ((isset($current_data['datos']))
&& ($current_data['datos'] !== false) && ($current_data['datos'] !== false)
) { ) {
@ -6159,7 +6165,7 @@ function reporting_advanced_sla(
$match = preg_match('/'.$max_value.'/', $current_data['datos']); $match = preg_match('/'.$max_value.'/', $current_data['datos']);
} }
// Take notice of $inverse_interval value, // Take notice of $inverse_interval value.
if ($inverse_interval == 0) { if ($inverse_interval == 0) {
$sla_check_value = $match; $sla_check_value = $match;
} else { } else {
@ -6176,19 +6182,41 @@ function reporting_advanced_sla(
// Not unknown nor not init values. // Not unknown nor not init values.
if ($sla_check_value) { if ($sla_check_value) {
$ok_checks++; if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)
) {
$ok_checks++;
}
$time_in_ok += $time_interval; $time_in_ok += $time_interval;
} else { } else {
$bad_checks++; if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)
) {
$bad_checks++;
}
$time_in_error += $time_interval; $time_in_error += $time_interval;
} }
} else { } else {
if ($current_data['datos'] === null) { if ($current_data['datos'] === null) {
$time_in_unknown += $time_interval; $time_in_unknown += $time_interval;
$unknown_checks++; if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)
) {
$unknown_checks++;
}
} else if ($current_data['datos'] === false) { } else if ($current_data['datos'] === false) {
$time_in_not_init += $time_interval; $time_in_not_init += $time_interval;
$not_init_checks++; if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)
) {
$not_init_checks++;
}
} }
} }
} }

View File

@ -159,7 +159,7 @@ function snmp_browser_get_html_tree(
$status = (!empty($checked) && isset($checked[$level])); $status = (!empty($checked) && isset($checked[$level]));
$output .= html_print_checkbox($checkbox_name, 0, $status, true, false, '').'&nbsp;<span>'.$level.'</span>'; $output .= html_print_checkbox($checkbox_name, 0, $status, true, false, '').'&nbsp;<span>'.$level.'</span>';
if (isset($sub_level['__VALUE__'])) { if (isset($sub_level['__VALUE__'])) {
$output .= '<span class="value" style="display: none;">&nbsp;=&nbsp;'.$sub_level['__VALUE__'].'</span>'; $output .= '<span class="value" style="display: none;">&nbsp;=&nbsp;'.io_safe_input($sub_level['__VALUE__']).'</span>';
} }
$output .= '</li>'; $output .= '</li>';

View File

@ -129,7 +129,7 @@
<div style='height: 10px'> <div style='height: 10px'>
<?php <?php
$version = '7.0NG.746'; $version = '7.0NG.746';
$build = '200617'; $build = '200619';
$banner = "v$version Build $build"; $banner = "v$version Build $build";
error_reporting(0); error_reporting(0);

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name httpd %define httpd_name httpd

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name httpd %define httpd_name httpd

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
%define httpd_name httpd %define httpd_name httpd
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name apache2 %define httpd_name apache2

View File

@ -1,5 +1,5 @@
package: pandorafms-server package: pandorafms-server
Version: 7.0NG.746-200617 Version: 7.0NG.746-200619
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.746-200617" pandora_version="7.0NG.746-200619"
package_cpan=0 package_cpan=0
package_pandora=1 package_pandora=1

View File

@ -45,7 +45,7 @@ our @EXPORT = qw(
# version: Defines actual version of Pandora Server for this module only # version: Defines actual version of Pandora Server for this module only
my $pandora_version = "7.0NG.746"; my $pandora_version = "7.0NG.746";
my $pandora_build = "200617"; my $pandora_build = "200619";
our $VERSION = $pandora_version." ".$pandora_build; our $VERSION = $pandora_version." ".$pandora_build;
# Setup hash # Setup hash

View File

@ -33,7 +33,7 @@ our @ISA = qw(Exporter);
# version: Defines actual version of Pandora Server for this module only # version: Defines actual version of Pandora Server for this module only
my $pandora_version = "7.0NG.746"; my $pandora_version = "7.0NG.746";
my $pandora_build = "200617"; my $pandora_build = "200619";
our $VERSION = $pandora_version." ".$pandora_build; our $VERSION = $pandora_version." ".$pandora_build;
our %EXPORT_TAGS = ( 'all' => [ qw() ] ); our %EXPORT_TAGS = ( 'all' => [ qw() ] );

View File

@ -40,6 +40,7 @@ use constant {
DISCOVERY_CLOUD_AZURE_COMPUTE => 8, DISCOVERY_CLOUD_AZURE_COMPUTE => 8,
DISCOVERY_DEPLOY_AGENTS => 9, DISCOVERY_DEPLOY_AGENTS => 9,
DISCOVERY_APP_SAP => 10, DISCOVERY_APP_SAP => 10,
DISCOVERY_APP_DB2 => 11,
DISCOVERY_REVIEW => 0, DISCOVERY_REVIEW => 0,
DISCOVERY_STANDARD => 1, DISCOVERY_STANDARD => 1,
DISCOVERY_RESULTS => 2, DISCOVERY_RESULTS => 2,
@ -1661,6 +1662,9 @@ sub database_scan($$$) {
# Skip database scan in Oracle tasks # Skip database scan in Oracle tasks
next if defined($self->{'type'}) && $self->{'type'} == DISCOVERY_APP_ORACLE; next if defined($self->{'type'}) && $self->{'type'} == DISCOVERY_APP_ORACLE;
# Skip database scan in DB2 tasks
next if defined($self->{'type'}) && $self->{'type'} == DISCOVERY_APP_DB2;
my $__data = $obj->scan_databases(); my $__data = $obj->scan_databases();
if (ref($__data) eq "ARRAY") { if (ref($__data) eq "ARRAY") {
@ -1705,6 +1709,8 @@ sub app_scan($) {
$type = 'MySQL'; $type = 'MySQL';
} elsif ($self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE) { } elsif ($self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE) {
$type = 'Oracle'; $type = 'Oracle';
} elsif ($self->{'task_data'}->{'type'} == DISCOVERY_APP_DB2) {
$type = 'DB2';
} elsif ($self->{'task_data'}->{'type'} == DISCOVERY_APP_SAP) { } elsif ($self->{'task_data'}->{'type'} == DISCOVERY_APP_SAP) {
$type = 'SAP'; $type = 'SAP';
} else { } else {
@ -1787,7 +1793,9 @@ sub app_scan($) {
# Scan connected obj. # Scan connected obj.
if ( $self->{'task_data'}->{'type'} == DISCOVERY_APP_MYSQL if ( $self->{'task_data'}->{'type'} == DISCOVERY_APP_MYSQL
|| $self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE) { || $self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE
|| $self->{'task_data'}->{'type'} == DISCOVERY_APP_DB2
) {
# Database. # Database.
$results = $self->database_scan($type, $obj, $global_percent, \@targets); $results = $self->database_scan($type, $obj, $global_percent, \@targets);
@ -1894,6 +1902,7 @@ sub scan($) {
if (defined($self->{'task_data'})) { if (defined($self->{'task_data'})) {
if ( $self->{'task_data'}->{'type'} == DISCOVERY_APP_MYSQL if ( $self->{'task_data'}->{'type'} == DISCOVERY_APP_MYSQL
|| $self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE || $self->{'task_data'}->{'type'} == DISCOVERY_APP_ORACLE
|| $self->{'task_data'}->{'type'} == DISCOVERY_APP_DB2
|| $self->{'task_data'}->{'type'} == DISCOVERY_APP_SAP) { || $self->{'task_data'}->{'type'} == DISCOVERY_APP_SAP) {
# Application scan. # Application scan.
$self->call('message', "Scanning application ...", 6); $self->call('message', "Scanning application ...", 6);

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_server %define name pandorafms_server
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
Summary: Pandora FMS Server Summary: Pandora FMS Server
Name: %{name} Name: %{name}

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_server %define name pandorafms_server
%define version 7.0NG.746 %define version 7.0NG.746
%define release 200617 %define release 200619
Summary: Pandora FMS Server Summary: Pandora FMS Server
Name: %{name} Name: %{name}

View File

@ -9,7 +9,7 @@
# ********************************************************************** # **********************************************************************
PI_VERSION="7.0NG.746" PI_VERSION="7.0NG.746"
PI_BUILD="200617" PI_BUILD="200619"
MODE=$1 MODE=$1
if [ $# -gt 1 ]; then if [ $# -gt 1 ]; then

View File

@ -35,7 +35,7 @@ use PandoraFMS::Config;
use PandoraFMS::DB; use PandoraFMS::DB;
# version: define current version # version: define current version
my $version = "7.0NG.746 PS200617"; my $version = "7.0NG.746 PS200619";
# Pandora server configuration # Pandora server configuration
my %conf; my %conf;

View File

@ -36,7 +36,7 @@ use Encode::Locale;
Encode::Locale::decode_argv; Encode::Locale::decode_argv;
# version: define current version # version: define current version
my $version = "7.0NG.746 PS200617"; my $version = "7.0NG.746 PS200619";
# save program name for logging # save program name for logging
my $progname = basename($0); my $progname = basename($0);