Table of Contents

Security Architecture

Introduction

The security elements of each Pandora FMS component are described, according to regulations such as PCI/DSS, ISO 27001, ENS, LOPD and similar.

In addition, a specific description of the security mechanisms of each Pandora FMS element is included, as well as the possible risks and the way to mitigate them, using the tools available in Pandora FMS or other possible mechanisms.

General security implementation

Security by architecture components

Server

Potential vulnerabilities and safeguards

Solution: Implement an external secured container for external configuration files, through NFS.

Solution: Disable remote configuration on particularly sensitive EndPoints after configuration and leave them running without being able to alter anything remotely, for the utmost security. Remote monitoring - without agents - of the most sensitive devices.

  1. Password protection procedure (which works per group).
  2. Limiting agent auto-creation EndPoint data, and creating them manually.
  3. Limiting the ability to auto-detect changes in agents and not taking new information from the XML (EndPoints) to the existing one.

Solution: Enable TLS communication between server and MySQL database. Configure the authentication method caching_sha2_password.

Tentacle

Potential vulnerabilities and safeguards

Solution: It is protected in the same way as the server, by means of a secured external NFS system.

Solutions: Build a HA Solution on the TCP service offered for balancing, or an active/active cluster. Any available hardware or software Solution is acceptable as it is a standard TCP service.

Web console

Potential vulnerabilities and safeguards

Solution: It is protected in the same way as the server, by means of a secured external NFS system.

Solutions:

  1. Implement a complex password policy.
  2. Implement a double authentication mechanism.

Solution: Implement SSL/TLS.

Solution: Implement SSL/TLS.

Solution: Implement encrypted data storage.

Solutions:

  1. Activate the audit log and show users that it exists and its accuracy.
  2. Activate the extended ACL system to restrict the roles of each user as much as possible.
  3. Export the audit log to an external system on a regular basis.

Solution: Strengthening (hardening) of the server containing the application.

Agents (EndPoints)

Potential vulnerabilities and safeguards

Solutions:

  1. Limit which users may perform these policy or configuration modifications (via ordinary console ACL or extended ACL).
  2. Activate the read-only mode (readonly) of the agents (do not allow remote modifications of their configuration), for those particularly sensitive systems.

Solution: Correct permission configuration.

Solutions:

  1. Limit which users may upload executables (though ordinary console ACL or extended ACL).
  2. Perform an audit of newplugins.

Database

Potential vulnerabilities and safeguards

Solution: Implementation of a secure TLS connection. MySQL supports it.

Solution: Correct configuration of access permissions.

Basic System Assurance

System hardening is a key point in a company's overall security strategy.

As manufacturers, we issue a series of recommendations to perform a safe installation of all Pandora FMS components, based on a standard RHEL 8 or Ubuntu server platform.

These same recommendations are valid for any other Linux based monitoring system.

Access credentials

To access the system, nominative access users will be created, without privileges and with access restricted to the needs they have.

Ideally, each user's authentication should be integrated with a double authentication system based on tokens. There are free and safe alternatives such as Google Authenticator® that can be integrated into Linux and are beyond the scope of this guide. Seriously consider using them.

If it is necessary to create other users for applications, they must be users without remote access (to do so, disable their Shell or equivalent method).

Superuser access

In case certain users need to have administrator permissions, the sudo command is used.

Updated operating system

You only need to be connected to the Internet or configure the dnf or apt system to use a proxy server.

This command can cause potential problems with changing libraries, configurations, and so on. It is important to update the operating system before putting the system into production. If you are overhauling an already active production system, you may only need to upgrade critical components, for example those that have a vulnerability.

For example to upgrade only MySQL on a RHEL system: dnf update mysql-server.

Updating the operating system is a process that should be performed periodically. Vulnerable versions can be queried and emergency updates can be executed by means of the system package inventory.

Access audit

It is necessary to have the security log /var/log/secure active and monitor those logs ith monitoring.

By default this is enabled, if it is not, check the file /etc/rsyslog.conf or /etc/syslog.conf.

It is recommended that the logs of the audit system be carried and collected with an external log management system. Pandora FMS can do it and it will be useful to establish alerts or review them in a centralized way in case of need.

SSH Server

The SSH server allows remote connection to Linux systems for command execution, so it is a critical point and must be ensured by paying attention to the following points (to do so, edit the file /etc/ssh/sshd_config and then restart the service).

#Port 22     ->     Port 31122
#PermitRootLogin yes        ->    PermitRootLogin no
#AllowTcpForwarding yes        ->    AllowTcpForwarding no
#PermitTunnel no        ->    PermitTunnel no
Banner /etc/issue.net

MySQL server

If MySQL only provides services to an internal element, verify with netstat that it only listens on localhost:

netstat -an | grep 3306 | grep LIST
tcp        0      0 0.0.0.0:3306            0.0.0.0:*               LISTEN

In the previous example you are listening without restrictions, edit the file /etc/my.cnf, section [mysqld], adding the following line:

bind-address = 127.0.0.1

After restarting the service, check the listening port again.

MySQL password

Connect to the MySQL console with a privileged user:

mysql -h host -u root -p

Verify that the password is complex and that you requested a password. If not, it is set with the command:

mysqladmin password

This security measure is essential to protect databases not only against external attacks but also against misuse by internal users.

Apache web server

ServerTokens Prod

Add the above line to hide the web server version (Apache, Nginx) in the server information headers:

PHP application engine

To secure the application engine on which Pandora FMS runs, it may be necessary, in some particularly security-sensitive environments, to secure access to the application so that session cookies are only transmitted with SSL.

This will cause the application to not work when used over HTTP (without encryption).

To do this, the following configuration tokens must be included in the php.ini file:

session.cookie_httponly = 1
session.cookie_secure = 1

Minimize services in the system

This technique, which can be very thorough, consists of removing everything unnecessary on the system. This avoids possible problems in the future with misconfigured applications that are not really needed. To simplify the approach to this practice, consider only those applications that have an open port on the machine, for that run: netstat -tulpn.

Each port should be investigated and the application behind it should be known. To do this you can use the lsof command, which must be installed with dnf or apt.

Those services listening on localhost (127.0.0.1) are safer than those listening to all IP addresses (0.0.0.0) and some of them, if they are listening on an open port, you should try to correct them to listen only to localhost.

By means of Pandora FMS process inventory system, it should be verified that no new processes are started over time.

Additional configuration

NTP time synchronization

It is recommended to configure system time synchronization on a RHEL system:

dnf install ntpdate
echo "ntpdate 0.us.pool.ntp.org"> /etc/cron.daily/ntp
chmod 755 /etc/cron.daily/ntp

Local monitoring

The system should have an Pandora FMS EndPoint installed and executed in PFMS server. For MS Windows® operating system, from version 761 onwards, the executable's installation are digitally signed.

The following active checks are recommended in addition to the standard checks:

module_plugin grep_log_module /var/log/messages Syslog \.\*
module_plugin grep_log_module /var/log/secure Secure \.\*

Once the EndPoint is installed, at least the following information must be manually defined in the agent tab:

Linux security monitoring

The official plugin allows to proactively monitor security in the agent, at each execution, almost in real time, offering some checks that can alert of some relevant events.

This plugin is intended to run only on modern Linux® machines. It contains a custom build of John the ripper 1.8 + Contrib patches with static 32-bit and 64-bit binaries. The main concept of the plugin is to be monolithic, detect what can be hardened and try to resolve differences between distributions without asking anything to the administrator, so the deployment could be the same for any system, ignoring versions, distro or architecture.

This plugin will check:

Back to Pandora FMS Documentation Index