diff --git a/extras/deploy-scripts/deploy_ext_database_el8.sh b/extras/deploy-scripts/deploy_ext_database_el8.sh
index 3ff86cc56b..4417265599 100644
--- a/extras/deploy-scripts/deploy_ext_database_el8.sh
+++ b/extras/deploy-scripts/deploy_ext_database_el8.sh
@@ -19,10 +19,10 @@ LOGFILE="/tmp/deploy-ext-db-$(date +%F).log"
[ "$DBHOST" ] || DBHOST=127.0.0.1
[ "$DBNAME" ] || DBNAME=pandora
[ "$DBUSER" ] || DBUSER=pandora
-[ "$DBPASS" ] || DBPASS=pandora
+[ "$DBPASS" ] || DBPASS='Pandor4!'
[ "$DBPORT" ] || DBPORT=3306
[ "$DBROOTUSER" ] || DBROOTUSER=root
-[ "$DBROOTPASS" ] || DBROOTPASS=pandora
+[ "$DBROOTPASS" ] || DBROOTPASS='Pandor4!'
[ "$SKIP_DATABASE_INSTALL" ] || SKIP_DATABASE_INSTALL=0
[ "$SKIP_KERNEL_OPTIMIZATIONS" ] || SKIP_KERNEL_OPTIMIZATIONS=0
[ "$POOL_SIZE" ] || POOL_SIZE=$(grep -i total /proc/meminfo | head -1 | awk '{printf "%.2f \n", $(NF-1)*0.4/1024}' | sed "s/\\..*$/M/g")
@@ -79,6 +79,53 @@ check_root_permissions () {
fi
}
+# Function to check if a password meets the MySQL secure password requirements
+is_mysql_secure_password() {
+ local password=$1
+
+ # Check password length (at least 8 characters)
+ if [[ ${#password} -lt 8 ]]; then
+ echo "Password length should be at least 8 characters."
+ return 1
+ fi
+
+ # Check if password contains at least one uppercase letter
+ if [[ $password == ${password,,} ]]; then
+ echo "Password should contain at least one uppercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one lowercase letter
+ if [[ $password == ${password^^} ]]; then
+ echo "Password should contain at least one lowercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one digit
+ if ! [[ $password =~ [0-9] ]]; then
+ echo "Password should contain at least one digit."
+ return 1
+ fi
+
+ # Check if password contains at least one special character
+ if ! [[ $password =~ [[:punct:]] ]]; then
+ echo "Password should contain at least one special character."
+ return 1
+ fi
+
+ # Check if password is not a common pattern (e.g., "password", "123456")
+ local common_patterns=("password" "123456" "qwerty")
+ for pattern in "${common_patterns[@]}"; do
+ if [[ $password == *"$pattern"* ]]; then
+ echo "Password should not contain common patterns."
+ return 1
+ fi
+ done
+
+ # If all checks pass, the password is MySQL secure compliant
+ return 0
+}
+
## Main
echo "Starting PandoraFMS External DB deployment EL8 ver. $S_VERSION"
@@ -128,6 +175,10 @@ execute_cmd "grep --version" 'Checking needed tools: grep'
execute_cmd "sed --version" 'Checking needed tools: sed'
execute_cmd "dnf --version" 'Checking needed tools: dnf'
+#Check mysql pass
+execute_cmd "is_mysql_secure_password $DBROOTPASS" "Checking DBROOTPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+execute_cmd "is_mysql_secure_password $DBPASS" "Checking DBPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+
# Creating working directory
rm -rf "$HOME"/pandora_deploy_tmp/*.rpm* &>> "$LOGFILE"
mkdir "$HOME"/pandora_deploy_tmp &>> "$LOGFILE"
@@ -207,16 +258,12 @@ if [ "$SKIP_DATABASE_INSTALL" -eq '0' ] ; then
export MYSQL_PWD=$(grep "temporary password" /var/log/mysqld.log | rev | cut -d' ' -f1 | rev)
if [ "$MYVER" -eq '80' ] ; then
echo """
- SET PASSWORD FOR '$DBROOTUSER'@'localhost' = 'Pandor4!';
- UNINSTALL COMPONENT 'file://component_validate_password';
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = '$DBROOTPASS';
""" | mysql --connect-expired-password -u$DBROOTUSER &>> "$LOGFILE"
fi
if [ "$MYVER" -ne '80' ] ; then
echo """
- SET PASSWORD FOR '$DBROOTUSER'@'localhost' = PASSWORD('Pandor4!');
- UNINSTALL PLUGIN validate_password;
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = PASSWORD('$DBROOTPASS');
""" | mysql --connect-expired-password -u$DBROOTUSER &>> "$LOGFILE"fi
fi
diff --git a/extras/deploy-scripts/deploy_ext_database_ubuntu_2204.sh b/extras/deploy-scripts/deploy_ext_database_ubuntu_2204.sh
index 21f9b21fa0..767be5632f 100644
--- a/extras/deploy-scripts/deploy_ext_database_ubuntu_2204.sh
+++ b/extras/deploy-scripts/deploy_ext_database_ubuntu_2204.sh
@@ -26,9 +26,9 @@ rm -f $LOGFILE &> /dev/null # remove last log before start
[ "$DBHOST" ] || DBHOST=127.0.0.1
[ "$DBNAME" ] || DBNAME=pandora
[ "$DBUSER" ] || DBUSER=pandora
-[ "$DBPASS" ] || DBPASS=pandora
+[ "$DBPASS" ] || DBPASS='Pandor4!'
[ "$DBPORT" ] || DBPORT=3306
-[ "$DBROOTPASS" ] || DBROOTPASS=pandora
+[ "$DBROOTPASS" ] || DBROOTPASS='Pandor4!'
[ "$SKIP_DATABASE_INSTALL" ] || SKIP_DATABASE_INSTALL=0
[ "$SKIP_KERNEL_OPTIMIZATIONS" ] || SKIP_KERNEL_OPTIMIZATIONS=0
[ "$POOL_SIZE" ] || POOL_SIZE=$(grep -i total /proc/meminfo | head -1 | awk '{printf "%.2f \n", $(NF-1)*0.4/1024}' | sed "s/\\..*$/M/g")
@@ -86,6 +86,53 @@ check_root_permissions () {
fi
}
+# Function to check if a password meets the MySQL secure password requirements
+is_mysql_secure_password() {
+ local password=$1
+
+ # Check password length (at least 8 characters)
+ if [[ ${#password} -lt 8 ]]; then
+ echo "Password length should be at least 8 characters."
+ return 1
+ fi
+
+ # Check if password contains at least one uppercase letter
+ if [[ $password == ${password,,} ]]; then
+ echo "Password should contain at least one uppercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one lowercase letter
+ if [[ $password == ${password^^} ]]; then
+ echo "Password should contain at least one lowercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one digit
+ if ! [[ $password =~ [0-9] ]]; then
+ echo "Password should contain at least one digit."
+ return 1
+ fi
+
+ # Check if password contains at least one special character
+ if ! [[ $password =~ [[:punct:]] ]]; then
+ echo "Password should contain at least one special character."
+ return 1
+ fi
+
+ # Check if password is not a common pattern (e.g., "password", "123456")
+ local common_patterns=("password" "123456" "qwerty")
+ for pattern in "${common_patterns[@]}"; do
+ if [[ $password == *"$pattern"* ]]; then
+ echo "Password should not contain common patterns."
+ return 1
+ fi
+ done
+
+ # If all checks pass, the password is MySQL secure compliant
+ return 0
+}
+
## Main
echo "Starting PandoraFMS External DB deployment Ubuntu 22.04 ver. $S_VERSION"
@@ -137,6 +184,10 @@ execute_cmd "grep --version" 'Checking needed tools: grep'
execute_cmd "sed --version" 'Checking needed tools: sed'
execute_cmd "apt --version" 'Checking needed tools: apt'
+#Check mysql pass
+execute_cmd "is_mysql_secure_password $DBROOTPASS" "Checking DBROOTPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+execute_cmd "is_mysql_secure_password $DBPASS" "Checking DBPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+
# Creating working directory
rm -rf "$WORKDIR" &>> "$LOGFILE"
mkdir -p "$WORKDIR" &>> "$LOGFILE"
@@ -170,6 +221,7 @@ if [ "$SKIP_DATABASE_INSTALL" -eq '0' ] ; then
""" | mysql -uroot &>> "$LOGFILE"
export MYSQL_PWD=$DBROOTPASS
+ echo "INSTALL COMPONENT 'file://component_validate_password';" | mysql -uroot -P$DBPORT -h$DBHOST &>> "$LOGFILE"
echo -en "${cyan}Creating Pandora FMS database...${reset}"
echo "create database $DBNAME" | mysql -uroot -P$DBPORT -h$DBHOST
check_cmd_status "Error creating database $DBNAME, is this an empty node? if you have a previus installation please contact with support."
diff --git a/extras/deploy-scripts/pandora_deploy_community.sh b/extras/deploy-scripts/pandora_deploy_community.sh
index 2e40524588..c16729bca0 100644
--- a/extras/deploy-scripts/pandora_deploy_community.sh
+++ b/extras/deploy-scripts/pandora_deploy_community.sh
@@ -11,7 +11,7 @@ PANDORA_SERVER_CONF=/etc/pandora/pandora_server.conf
PANDORA_AGENT_CONF=/etc/pandora/pandora_agent.conf
-S_VERSION='2023050901'
+S_VERSION='2023062901'
LOGFILE="/tmp/pandora-deploy-community-$(date +%F).log"
# define default variables
@@ -285,8 +285,7 @@ console_dependencies=" \
mod_ssl \
libzstd \
openldap-clients \
- chromium \
- http://firefly.pandorafms.com/centos8/phantomjs-2.1.1-1.el7.x86_64.rpm"
+ chromium"
execute_cmd "yum install -y $console_dependencies" "Installing Pandora FMS Console dependencies"
# Server dependencies
@@ -313,7 +312,6 @@ server_dependencies=" \
bind-utils \
whois \
cpanminus \
- http://firefly.pandorafms.com/centos7/xprobe2-0.3-12.2.x86_64.rpm \
http://firefly.pandorafms.com/centos7/wmic-1.4-1.el7.x86_64.rpm \
https://firefly.pandorafms.com/centos7/pandorawmic-1.0.0-1.x86_64.rpm"
execute_cmd "yum install -y $server_dependencies" "Installing Pandora FMS Server dependencies"
@@ -341,7 +339,6 @@ execute_cmd "yum install -y $oracle_dependencies || yum reinstall -y $oracle_dep
#ipam dependencies
ipam_dependencies=" \
- http://firefly.pandorafms.com/centos7/xprobe2-0.3-12.2.x86_64.rpm \
perl(NetAddr::IP) \
perl(Sys::Syslog) \
perl(DBI) \
@@ -719,6 +716,9 @@ echo "* * * * * root wget -q -O - --no-check-certificate --load-cookies /tmp/cro
systemctl enable pandora_agent_daemon &>> $LOGFILE
execute_cmd "systemctl start pandora_agent_daemon" "Starting Pandora FMS Agent"
+# Enable postrix
+systemctl enable postfix --now &>> "$LOGFILE"
+
#SSH banner
[ "$(curl -s ifconfig.me)" ] && ipplublic=$(curl -s ifconfig.me)
diff --git a/extras/deploy-scripts/pandora_deploy_community_el8.sh b/extras/deploy-scripts/pandora_deploy_community_el8.sh
index 972a094c95..32422ab98b 100644
--- a/extras/deploy-scripts/pandora_deploy_community_el8.sh
+++ b/extras/deploy-scripts/pandora_deploy_community_el8.sh
@@ -14,7 +14,7 @@ PANDORA_SERVER_CONF=/etc/pandora/pandora_server.conf
PANDORA_AGENT_CONF=/etc/pandora/pandora_agent.conf
-S_VERSION='2023050901'
+S_VERSION='2023062901'
LOGFILE="/tmp/pandora-deploy-community-$(date +%F).log"
# define default variables
@@ -24,10 +24,10 @@ LOGFILE="/tmp/pandora-deploy-community-$(date +%F).log"
[ "$DBHOST" ] || DBHOST=127.0.0.1
[ "$DBNAME" ] || DBNAME=pandora
[ "$DBUSER" ] || DBUSER=pandora
-[ "$DBPASS" ] || DBPASS=pandora
+[ "$DBPASS" ] || DBPASS='Pandor4!'
[ "$DBPORT" ] || DBPORT=3306
[ "$DBROOTUSER" ] || DBROOTUSER=root
-[ "$DBROOTPASS" ] || DBROOTPASS=pandora
+[ "$DBROOTPASS" ] || DBROOTPASS='Pandor4!'
[ "$SKIP_PRECHECK" ] || SKIP_PRECHECK=0
[ "$SKIP_DATABASE_INSTALL" ] || SKIP_DATABASE_INSTALL=0
[ "$SKIP_KERNEL_OPTIMIZATIONS" ] || SKIP_KERNEL_OPTIMIZATIONS=0
@@ -125,6 +125,52 @@ installing_docker () {
echo "End installig docker" &>> "$LOGFILE"
}
+# Function to check if a password meets the MySQL secure password requirements
+is_mysql_secure_password() {
+ local password=$1
+
+ # Check password length (at least 8 characters)
+ if [[ ${#password} -lt 8 ]]; then
+ echo "Password length should be at least 8 characters."
+ return 1
+ fi
+
+ # Check if password contains at least one uppercase letter
+ if [[ $password == ${password,,} ]]; then
+ echo "Password should contain at least one uppercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one lowercase letter
+ if [[ $password == ${password^^} ]]; then
+ echo "Password should contain at least one lowercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one digit
+ if ! [[ $password =~ [0-9] ]]; then
+ echo "Password should contain at least one digit."
+ return 1
+ fi
+
+ # Check if password contains at least one special character
+ if ! [[ $password =~ [[:punct:]] ]]; then
+ echo "Password should contain at least one special character."
+ return 1
+ fi
+
+ # Check if password is not a common pattern (e.g., "password", "123456")
+ local common_patterns=("password" "123456" "qwerty")
+ for pattern in "${common_patterns[@]}"; do
+ if [[ $password == *"$pattern"* ]]; then
+ echo "Password should not contain common patterns."
+ return 1
+ fi
+ done
+
+ # If all checks pass, the password is MySQL secure compliant
+ return 0
+}
## Main
echo "Starting PandoraFMS Community deployment EL8 ver. $S_VERSION"
@@ -189,6 +235,10 @@ execute_cmd "grep --version" 'Checking needed tools: grep'
execute_cmd "sed --version" 'Checking needed tools: sed'
execute_cmd "dnf --version" 'Checking needed tools: dnf'
+#Check mysql pass
+execute_cmd "is_mysql_secure_password $DBROOTPASS" "Checking DBROOTPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+execute_cmd "is_mysql_secure_password $DBPASS" "Checking DBPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+
# Creating working directory
rm -rf "$HOME"/pandora_deploy_tmp/*.rpm* &>> "$LOGFILE"
mkdir "$HOME"/pandora_deploy_tmp &>> "$LOGFILE"
@@ -344,8 +394,7 @@ console_dependencies=" \
http://firefly.pandorafms.com/centos8/chromium-110.0.5481.177-1.el7.x86_64.rpm \
http://firefly.pandorafms.com/centos8/chromium-common-110.0.5481.177-1.el7.x86_64.rpm \
http://firefly.pandorafms.com/centos8/perl-Net-Telnet-3.04-1.el8.noarch.rpm \
- http://firefly.pandorafms.com/centos7/wmic-1.4-1.el7.x86_64.rpm \
- http://firefly.pandorafms.com/centos8/phantomjs-2.1.1-1.el7.x86_64.rpm"
+ http://firefly.pandorafms.com/centos7/wmic-1.4-1.el7.x86_64.rpm"
execute_cmd "dnf install -y $console_dependencies" "Installing Pandora FMS Console dependencies"
# Server dependencies
@@ -371,7 +420,7 @@ server_dependencies=" \
java \
bind-utils \
whois \
- http://firefly.pandorafms.com/centos7/xprobe2-0.3-12.2.x86_64.rpm \
+ libnsl \
http://firefly.pandorafms.com/centos7/wmic-1.4-1.el7.x86_64.rpm \
https://firefly.pandorafms.com/centos8/pandorawmic-1.0.0-1.x86_64.rpm"
execute_cmd "dnf install -y $server_dependencies" "Installing Pandora FMS Server dependencies"
@@ -399,7 +448,6 @@ execute_cmd "dnf install -y $oracle_dependencies" "Installing Oracle Instant cli
#ipam dependencies
ipam_dependencies=" \
- http://firefly.pandorafms.com/centos7/xprobe2-0.3-12.2.x86_64.rpm \
perl(NetAddr::IP) \
perl(Sys::Syslog) \
perl(DBI) \
@@ -439,7 +487,6 @@ if [ "$SKIP_DATABASE_INSTALL" -eq '0' ] ; then
if [ "$MYVER" -eq '80' ] ; then
echo """
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = 'Pandor4!';
- UNINSTALL COMPONENT 'file://component_validate_password';
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = '$DBROOTPASS';
""" | mysql --connect-expired-password -u$DBROOTUSER &>> "$LOGFILE"
fi
@@ -447,7 +494,6 @@ if [ "$SKIP_DATABASE_INSTALL" -eq '0' ] ; then
if [ "$MYVER" -ne '80' ] ; then
echo """
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = PASSWORD('Pandor4!');
- UNINSTALL PLUGIN validate_password;
SET PASSWORD FOR '$DBROOTUSER'@'localhost' = PASSWORD('$DBROOTPASS');
""" | mysql --connect-expired-password -u$DBROOTUSER &>> "$LOGFILE"fi
fi
@@ -622,8 +668,9 @@ sed -i -e "s/^upload_max_filesize.*/upload_max_filesize = 800M/g" /etc/php.ini
sed -i -e "s/^memory_limit.*/memory_limit = 800M/g" /etc/php.ini
sed -i -e "s/.*post_max_size =.*/post_max_size = 800M/" /etc/php.ini
-#adding 900s to httpd timeout
+#adding 900s to httpd timeout and 300 to ProxyTimeout
echo 'TimeOut 900' > /etc/httpd/conf.d/timeout.conf
+echo 'ProxyTimeout 300' >> /etc/httpd/conf.d/timeout.conf
cat > /var/www/html/index.html << EOF_INDEX
@@ -787,6 +834,9 @@ echo "* * * * * root wget -q -O - --no-check-certificate --load-cookies /tmp/cro
systemctl enable pandora_agent_daemon &>> "$LOGFILE"
execute_cmd "systemctl start pandora_agent_daemon" "Starting Pandora FMS Agent"
+# Enable postfix
+systemctl enable postfix --now &>> "$LOGFILE"
+
#SSH banner
[ "$(curl -s ifconfig.me)" ] && ipplublic=$(curl -s ifconfig.me)
diff --git a/extras/deploy-scripts/pandora_deploy_community_ubuntu_2204.sh b/extras/deploy-scripts/pandora_deploy_community_ubuntu_2204.sh
index 3d31ae10af..a215808d17 100644
--- a/extras/deploy-scripts/pandora_deploy_community_ubuntu_2204.sh
+++ b/extras/deploy-scripts/pandora_deploy_community_ubuntu_2204.sh
@@ -17,7 +17,7 @@ PANDORA_AGENT_CONF=/etc/pandora/pandora_agent.conf
WORKDIR=/opt/pandora/deploy
-S_VERSION='2023050901'
+S_VERSION='2023062901'
LOGFILE="/tmp/pandora-deploy-community-$(date +%F).log"
rm -f $LOGFILE &> /dev/null # remove last log before start
@@ -27,9 +27,9 @@ rm -f $LOGFILE &> /dev/null # remove last log before start
[ "$DBHOST" ] || DBHOST=127.0.0.1
[ "$DBNAME" ] || DBNAME=pandora
[ "$DBUSER" ] || DBUSER=pandora
-[ "$DBPASS" ] || DBPASS=pandora
+[ "$DBPASS" ] || DBPASS='Pandor4!'
[ "$DBPORT" ] || DBPORT=3306
-[ "$DBROOTPASS" ] || DBROOTPASS=pandora
+[ "$DBROOTPASS" ] || DBROOTPASS='Pandor4!'
[ "$SKIP_PRECHECK" ] || SKIP_PRECHECK=0
[ "$SKIP_DATABASE_INSTALL" ] || SKIP_DATABASE_INSTALL=0
[ "$SKIP_KERNEL_OPTIMIZATIONS" ] || SKIP_KERNEL_OPTIMIZATIONS=0
@@ -113,6 +113,53 @@ check_root_permissions () {
fi
}
+# Function to check if a password meets the MySQL secure password requirements
+is_mysql_secure_password() {
+ local password=$1
+
+ # Check password length (at least 8 characters)
+ if [[ ${#password} -lt 8 ]]; then
+ echo "Password length should be at least 8 characters."
+ return 1
+ fi
+
+ # Check if password contains at least one uppercase letter
+ if [[ $password == ${password,,} ]]; then
+ echo "Password should contain at least one uppercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one lowercase letter
+ if [[ $password == ${password^^} ]]; then
+ echo "Password should contain at least one lowercase letter."
+ return 1
+ fi
+
+ # Check if password contains at least one digit
+ if ! [[ $password =~ [0-9] ]]; then
+ echo "Password should contain at least one digit."
+ return 1
+ fi
+
+ # Check if password contains at least one special character
+ if ! [[ $password =~ [[:punct:]] ]]; then
+ echo "Password should contain at least one special character."
+ return 1
+ fi
+
+ # Check if password is not a common pattern (e.g., "password", "123456")
+ local common_patterns=("password" "123456" "qwerty")
+ for pattern in "${common_patterns[@]}"; do
+ if [[ $password == *"$pattern"* ]]; then
+ echo "Password should not contain common patterns."
+ return 1
+ fi
+ done
+
+ # If all checks pass, the password is MySQL secure compliant
+ return 0
+}
+
installing_docker () {
#Installing docker for debug
echo "Start installig docker" &>> "$LOGFILE"
@@ -194,6 +241,10 @@ execute_cmd "grep --version" 'Checking needed tools: grep'
execute_cmd "sed --version" 'Checking needed tools: sed'
execute_cmd "apt --version" 'Checking needed tools: apt'
+#Check mysql pass
+execute_cmd "is_mysql_secure_password $DBROOTPASS" "Checking DBROOTPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+execute_cmd "is_mysql_secure_password $DBPASS" "Checking DBPASS password match policy" 'This password do not match minimum MySQL policy requirements, more info in: https://dev.mysql.com/doc/refman/8.0/en/validate-password.html'
+
# Creating working directory
rm -rf "$WORKDIR" &>> "$LOGFILE"
mkdir -p "$WORKDIR" &>> "$LOGFILE"
@@ -265,7 +316,6 @@ server_dependencies=" \
openssh-client \
postfix \
unzip \
- xprobe \
coreutils \
libio-compress-perl \
libmoosex-role-timer-perl \
@@ -287,6 +337,8 @@ server_dependencies=" \
libgeo-ip-perl \
arping \
snmp-mibs-downloader \
+ snmptrapd \
+ libnsl2 \
openjdk-8-jdk "
execute_cmd "apt install -y $server_dependencies" "Installing Pandora FMS Server dependencies"
@@ -299,17 +351,7 @@ echo -en "${cyan}Installing wmic and pandorawmic...${reset}"
chmod +x pandorawmic wmic &>> "$LOGFILE" && \
cp -a wmic /usr/bin/ &>> "$LOGFILE" && \
cp -a pandorawmic /usr/bin/ &>> "$LOGFILE"
-check_cmd_status "Error Installing phanromjs"
-
-# phantomjs
-echo -en "${cyan}Installing phantomjs...${reset}"
- export PHANTOM_JS="phantomjs-2.1.1-linux-x86_64"
- export OPENSSL_CONF=/etc/ssl
- curl -LSs -O "https://firefly.pandorafms.com/pandorafms/utils/$PHANTOM_JS.tar.bz2" &>> "$LOGFILE" && \
- tar xvjf "$PHANTOM_JS.tar.bz2" &>> "$LOGFILE" && \
- mv $PHANTOM_JS/bin/phantomjs /usr/bin &>> "$LOGFILE" && \
- /usr/bin/phantomjs --version &>> "$LOGFILE"
-check_cmd_status "Error Installing phanromjs"
+check_cmd_status "Error Installing pandorawmic/wmic"
# create symlink for fping
rm -f /usr/sbin/fping &>> "$LOGFILE"
@@ -370,7 +412,6 @@ source '/root/.profile' &>> "$LOGFILE"
#ipam dependencies
ipam_dependencies=" \
- xprobe \
libnetaddr-ip-perl \
coreutils \
libdbd-mysql-perl \
@@ -413,6 +454,7 @@ if [ "$SKIP_DATABASE_INSTALL" -eq '0' ] ; then
""" | mysql -uroot &>> "$LOGFILE"
export MYSQL_PWD=$DBROOTPASS
+ echo "INSTALL COMPONENT 'file://component_validate_password';" | mysql -uroot -P$DBPORT -h$DBHOST &>> "$LOGFILE"
echo -en "${cyan}Creating Pandora FMS database...${reset}"
echo "create database $DBNAME" | mysql -uroot -P$DBPORT -h$DBHOST
check_cmd_status "Error creating database $DBNAME, is this an empty node? if you have a previus installation please contact with support."
@@ -619,8 +661,9 @@ sed --follow-symlinks -i -e "s/^memory_limit.*/memory_limit = 800M/g" /etc/php.i
sed --follow-symlinks -i -e "s/.*post_max_size =.*/post_max_size = 800M/" /etc/php.ini
sed --follow-symlinks -i -e "s/^disable_functions/;disable_functions/" /etc/php.ini
-#adding 900s to httpd timeout
-#echo 'TimeOut 900' > /etc/httpd/conf.d/timeout.conf
+#adding 900s to httpd timeout and 300 to ProxyTimeout
+echo 'TimeOut 900' > /etc/apache2/conf-enabled/timeout.conf
+echo 'ProxyTimeout 300' >> /etc/apache2/conf-enabled/timeout.conf
cat > /var/www/html/index.html << EOF_INDEX
@@ -792,6 +835,13 @@ systemctl enable pandora_agent_daemon &>> "$LOGFILE"
#fix path phantomjs
sed --follow-symlinks -i -e "s/^openssl_conf = openssl_init/#openssl_conf = openssl_init/g" /etc/ssl/openssl.cnf &>> "$LOGFILE"
+# Enable postfix
+systemctl enable postfix --now &>> "$LOGFILE"
+
+# Disable snmptrapd
+systemctl disable --now snmptrapd &>> "$LOGFILE"
+systemctl disable --now snmptrapd.socket &>> "$LOGFILE"
+
#SSH banner
[ "$(curl -s ifconfig.me)" ] && ipplublic=$(curl -s ifconfig.me)
diff --git a/extras/docker/centos8/docker-compose.yml b/extras/docker/centos8/docker-compose.yml
index 5ac5385133..37df7251f5 100644
--- a/extras/docker/centos8/docker-compose.yml
+++ b/extras/docker/centos8/docker-compose.yml
@@ -32,6 +32,7 @@ services:
PUBLICURL: ""
SLEEP: 5
RETRIES: 10
+ TZ: 'Europe/Madrid'
networks:
- pandora
ports:
diff --git a/extras/docker/centos8/pandora-stack/Dockerfile b/extras/docker/centos8/pandora-stack/Dockerfile
index 59728b37d6..65442a2588 100644
--- a/extras/docker/centos8/pandora-stack/Dockerfile
+++ b/extras/docker/centos8/pandora-stack/Dockerfile
@@ -10,6 +10,8 @@ ENV DBPORT=3306
ENV SLEEP=5
ENV RETRIES=1
ENV OPEN=1
+ENV TZ='Europe/Madrid'
+
ENV LC_ALL=C
diff --git a/extras/docker/centos8/pandora-stack/sources/init_pandora.sh b/extras/docker/centos8/pandora-stack/sources/init_pandora.sh
index e9265a0981..c27b5b35e0 100755
--- a/extras/docker/centos8/pandora-stack/sources/init_pandora.sh
+++ b/extras/docker/centos8/pandora-stack/sources/init_pandora.sh
@@ -230,6 +230,10 @@ fi
echo "" > /opt/pandora/crontasks || touch /opt/pandora/crontasks
+#set localtime
+rm -rf /etc/localtime
+ln -s /usr/share/zoneinfo/$TZ /etc/localtime
+
#install pandora packages
echo "-> Istalling pandorafms"
cd /opt/pandora
diff --git a/extras/pandora_update_version.sh b/extras/pandora_update_version.sh
index 71d29feb10..6554a81c84 100755
--- a/extras/pandora_update_version.sh
+++ b/extras/pandora_update_version.sh
@@ -28,6 +28,7 @@ $PANDHOME_ENT/pandora_server/PandoraFMS-Enterprise/pandora_server_enterprise.spe
$CODEHOME/pandora_console/pandora_console.redhat.spec \
$CODEHOME/pandora_console/pandora_console.rhel7.spec \
$CODEHOME/pandora_agents/unix/pandora_agent.redhat.spec \
+$CODEHOME/pandora_agents/unix/pandora_agent.redhat_bin.spec\
$CODEHOME/pandora_server/pandora_server.redhat.spec \
$PANDHOME_ENT/pandora_agents/pandora_agent.spec \
$PANDHOME_ENT/pandora_server/pandora_server_enterprise.redhat.spec \
diff --git a/pandora_agents/pc/AIX/pandora_agent.conf b/pandora_agents/pc/AIX/pandora_agent.conf
index 3b943f70a1..8e2d047bd5 100644
--- a/pandora_agents/pc/AIX/pandora_agent.conf
+++ b/pandora_agents/pc/AIX/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, AIX version
+# Version 7.0NG.773, AIX version
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/DEBIAN/control b/pandora_agents/pc/DEBIAN/control
index cdbcc99cfe..ac23fd959f 100644
--- a/pandora_agents/pc/DEBIAN/control
+++ b/pandora_agents/pc/DEBIAN/control
@@ -4,7 +4,7 @@ Architecture: all
Priority: optional
Section: admin
Installed-Size: 260
-Maintainer: ÁRTICA ST
+Maintainer: Pandora FMS
Homepage: https://pandorafms.org/
Depends: coreutils, perl, unzip
Description: Pandora FMS agents are based on native languages in every platform: scripts that can be written in any language. It’s possible to reproduce any agent in any programming language and can be extended without difficulty the existing ones in order to cover aspects not taken into account up to the moment. These scripts are formed by modules that each one gathers a "chunk" of information. Thus, every agent gathers several "chunks" of information; this one is organized in a data set and stored in a single file, called data file.
diff --git a/pandora_agents/pc/FreeBSD/pandora_agent.conf b/pandora_agents/pc/FreeBSD/pandora_agent.conf
index 099927e311..f63eda7230 100644
--- a/pandora_agents/pc/FreeBSD/pandora_agent.conf
+++ b/pandora_agents/pc/FreeBSD/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, FreeBSD Version
+# Version 7.0NG.773, FreeBSD Version
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/HP-UX/pandora_agent.conf b/pandora_agents/pc/HP-UX/pandora_agent.conf
index a433bce6d3..e22c6de293 100644
--- a/pandora_agents/pc/HP-UX/pandora_agent.conf
+++ b/pandora_agents/pc/HP-UX/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, HP-UX Version
+# Version 7.0NG.773, HP-UX Version
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/Linux/pandora_agent.conf b/pandora_agents/pc/Linux/pandora_agent.conf
index 7c43cc20d9..2461c8e348 100644
--- a/pandora_agents/pc/Linux/pandora_agent.conf
+++ b/pandora_agents/pc/Linux/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, GNU/Linux
+# Version 7.0NG.773, GNU/Linux
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/NT4/pandora_agent.conf b/pandora_agents/pc/NT4/pandora_agent.conf
index e02c49e8f3..a0121ee37b 100644
--- a/pandora_agents/pc/NT4/pandora_agent.conf
+++ b/pandora_agents/pc/NT4/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, GNU/Linux
+# Version 7.0NG.773, GNU/Linux
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/SunOS/pandora_agent.conf b/pandora_agents/pc/SunOS/pandora_agent.conf
index 7c2888babb..8196680c70 100644
--- a/pandora_agents/pc/SunOS/pandora_agent.conf
+++ b/pandora_agents/pc/SunOS/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, Solaris Version
+# Version 7.0NG.773, Solaris Version
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/pc/Win32/pandora_agent.conf b/pandora_agents/pc/Win32/pandora_agent.conf
index fad24aeaad..bf98ff3da8 100644
--- a/pandora_agents/pc/Win32/pandora_agent.conf
+++ b/pandora_agents/pc/Win32/pandora_agent.conf
@@ -1,6 +1,6 @@
# Base config file for Pandora FMS Windows Agent
# (c) 2006-2023 Pandora FMS
-# Version 7.0NG.772
+# Version 7.0NG.773
# 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
# Foundation; either version 2 of the Licence or any later version
diff --git a/pandora_agents/shellscript/aix/pandora_agent.conf b/pandora_agents/shellscript/aix/pandora_agent.conf
index e762cb74d0..2f974a3a1a 100644
--- a/pandora_agents/shellscript/aix/pandora_agent.conf
+++ b/pandora_agents/shellscript/aix/pandora_agent.conf
@@ -1,6 +1,6 @@
# Fichero de configuracion base de agentes de Pandora
# Base config file for Pandora agents
-# Version 7.0NG.772, AIX version
+# Version 7.0NG.773, AIX version
# General Parameters
# ==================
diff --git a/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf b/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf
index baeab23b20..2c188857a1 100644
--- a/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf
+++ b/pandora_agents/shellscript/bsd-ipso/pandora_agent.conf
@@ -1,6 +1,6 @@
# Fichero de configuracion base de agentes de Pandora
# Base config file for Pandora agents
-# Version 7.0NG.772
+# Version 7.0NG.773
# FreeBSD/IPSO version
# Licenced under GPL licence, 2003-2007 Sancho Lerena
diff --git a/pandora_agents/shellscript/hp-ux/pandora_agent.conf b/pandora_agents/shellscript/hp-ux/pandora_agent.conf
index 6ba4028df0..60664042dc 100644
--- a/pandora_agents/shellscript/hp-ux/pandora_agent.conf
+++ b/pandora_agents/shellscript/hp-ux/pandora_agent.conf
@@ -1,6 +1,6 @@
# Fichero de configuracion base de agentes de Pandora
# Base config file for Pandora agents
-# Version 7.0NG.772, HPUX Version
+# Version 7.0NG.773, HPUX Version
# General Parameters
# ==================
diff --git a/pandora_agents/shellscript/linux/DEBIAN/control b/pandora_agents/shellscript/linux/DEBIAN/control
index 55a5168f93..2ffdee57df 100755
--- a/pandora_agents/shellscript/linux/DEBIAN/control
+++ b/pandora_agents/shellscript/linux/DEBIAN/control
@@ -4,7 +4,7 @@ Architecture: all
Priority: optional
Section: admin
Installed-Size: 260
-Maintainer: ÁRTICA ST
+Maintainer: Pandora FMS
Homepage: http://pandorafms.org/
Depends: coreutils, perl
Description: Pandora FMS agents are based on native languages in every platform: scripts that can be written in any language. It’s possible to reproduce any agent in any programming language and can be extended without difficulty the existing ones in order to cover aspects not taken into account up to the moment. These scripts are formed by modules that each one gathers a "chunk" of information. Thus, every agent gathers several "chunks" of information; this one is organized in a data set and stored in a single file, called data file.
diff --git a/pandora_agents/shellscript/linux/pandora_agent.conf b/pandora_agents/shellscript/linux/pandora_agent.conf
index b366fd62f3..b15e1107d2 100644
--- a/pandora_agents/shellscript/linux/pandora_agent.conf
+++ b/pandora_agents/shellscript/linux/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772
+# Version 7.0NG.773
# Licensed under GPL license v2,
# (c) 2003-2023 Pandora FMS
# please visit http://pandora.sourceforge.net
diff --git a/pandora_agents/shellscript/mac_osx/pandora_agent.conf b/pandora_agents/shellscript/mac_osx/pandora_agent.conf
index e5aba369d4..f4d4d6bb62 100644
--- a/pandora_agents/shellscript/mac_osx/pandora_agent.conf
+++ b/pandora_agents/shellscript/mac_osx/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772
+# Version 7.0NG.773
# Licensed under GPL license v2,
# (c) 2003-2023 Pandora FMS
# please visit http://pandora.sourceforge.net
diff --git a/pandora_agents/shellscript/openWRT/pandora_agent.conf b/pandora_agents/shellscript/openWRT/pandora_agent.conf
index 12b2944fdd..9cac504e38 100644
--- a/pandora_agents/shellscript/openWRT/pandora_agent.conf
+++ b/pandora_agents/shellscript/openWRT/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772
+# Version 7.0NG.773
# Licensed under GPL license v2,
# please visit http://pandora.sourceforge.net
diff --git a/pandora_agents/shellscript/solaris/pandora_agent.conf b/pandora_agents/shellscript/solaris/pandora_agent.conf
index 130aa691f4..40ddbc04b6 100644
--- a/pandora_agents/shellscript/solaris/pandora_agent.conf
+++ b/pandora_agents/shellscript/solaris/pandora_agent.conf
@@ -1,6 +1,6 @@
# Fichero de configuracion base de agentes de Pandora
# Base config file for Pandora agents
-# Version 7.0NG.772, Solaris version
+# Version 7.0NG.773, Solaris version
# General Parameters
# ==================
diff --git a/pandora_agents/unix/AIX/pandora_agent.conf b/pandora_agents/unix/AIX/pandora_agent.conf
index 553e3c6999..1854b87b6c 100644
--- a/pandora_agents/unix/AIX/pandora_agent.conf
+++ b/pandora_agents/unix/AIX/pandora_agent.conf
@@ -1,5 +1,5 @@
# Base config file for Pandora FMS agents
-# Version 7.0NG.772, AIX version
+# Version 7.0NG.773, AIX version
# Licensed under GPL license v2,
# Copyright (c) 2003-2023 Pandora FMS
# http://www.pandorafms.com
diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control
index 9f2a0a04aa..f17d570a6c 100644
--- a/pandora_agents/unix/DEBIAN/control
+++ b/pandora_agents/unix/DEBIAN/control
@@ -1,10 +1,10 @@
package: pandorafms-agent-unix
-Version: 7.0NG.772-230714
+Version: 7.0NG.773-230818
Architecture: all
Priority: optional
Section: admin
Installed-Size: 260
-Maintainer: ÁRTICA ST
+Maintainer: Pandora FMS
Homepage: http://pandorafms.org/
Depends: coreutils, perl, unzip
Description: Pandora FMS agents are based on native languages in every platform: scripts that can be written in any language. It’s possible to reproduce any agent in any programming language and can be extended without difficulty the existing ones in order to cover aspects not taken into account up to the moment. These scripts are formed by modules that each one gathers a "chunk" of information. Thus, every agent gathers several "chunks" of information; this one is organized in a data set and stored in a single file, called data file.
diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh
index c0704f74a7..16aaa10b94 100644
--- a/pandora_agents/unix/DEBIAN/make_deb_package.sh
+++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh
@@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-pandora_version="7.0NG.772-230714"
+pandora_version="7.0NG.773-230818"
echo "Test if you has the tools for to make the packages."
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null
@@ -42,6 +42,7 @@ mkdir -p temp_package/usr/bin/
mkdir -p temp_package/usr/sbin/
mkdir -p temp_package/etc/pandora/plugins
mkdir -p temp_package/etc/pandora/collections
+mkdir -p temp_package/etc/pandora/ref
mkdir -p temp_package/etc/pandora/trans
mkdir -p temp_package/etc/pandora/commands
mkdir -p temp_package/etc/init.d/
diff --git a/pandora_agents/unix/Darwin/dmg/build_darwin_dmg.sh b/pandora_agents/unix/Darwin/dmg/build_darwin_dmg.sh
index 558aaecacf..6a9f7a5504 100644
--- a/pandora_agents/unix/Darwin/dmg/build_darwin_dmg.sh
+++ b/pandora_agents/unix/Darwin/dmg/build_darwin_dmg.sh
@@ -31,7 +31,7 @@ fi
if [ "$#" -ge 2 ]; then
VERSION="$2"
else
- VERSION="7.0NG.772"
+ VERSION="7.0NG.773"
fi
# Path for the generated DMG file
diff --git a/pandora_agents/unix/Darwin/dmg/extras/distribution.xml b/pandora_agents/unix/Darwin/dmg/extras/distribution.xml
index 198ea1d06a..e8bdaca067 100644
--- a/pandora_agents/unix/Darwin/dmg/extras/distribution.xml
+++ b/pandora_agents/unix/Darwin/dmg/extras/distribution.xml
@@ -19,11 +19,11 @@
- pandorafms_src.pdk
+ pandorafms_src.pdk
- pandorafms_uninstall.pdk
+ pandorafms_uninstall.pdk