ja:documentation:pandorafms:cybersecurity:07_safety_functions

文書の過去の版を表示しています。


セキュリティ機能

Default authentication indicates that it will be carried out using the internal Pandora FMS database. For security, superadmin type users are always authenticated in this way, the rest of the authentication types have the local option as a backup (fallback).

Pandora FMS 内部のデータベースを使用して実行するデフォルトの認証です。セキュリティのため、スーパー管理者タイプのユーザは常にこの方法で認証され、その他の認証タイプにはローカルバックアップ (フォールバック) オプションがあります。

  • Automatically create remote users: Enables or disables automatic creation of remote users. This option makes it possible for Pandora FMS to create users automatically once they log in. If you enable this feature, the following fields will be available:
  • Save Password: If activated, it allows you to save AD passwords in the local Pandora FMS database.
  • Advanced Configuration AD: If this option is enabled, the Advanced Permissions AD configuration will be used.
    • Advanced Permissions AD: Lists the advanced permissions that have been added in Add new permissions.
  • Automatically create profile: When the automatic creation of remote users is active, this field makes it possible to assign a type of profile to these users that are created automatically. The default profiles are: Chief Operator, Group Coordinator, Operator (Read), Operator (Write) and Pandora Administrator. The different profiles available can be consulted in the Profiles → Profile management section.
  • Automatically create profile group: When activating the automatic creation of remote users, this field makes it possible to assign a group to these automatically created users. The different groups available can be consulted in the Profiles → Manage agent groups section.
  • Automatically create profile tags: When the automatic creation of remote users is active, this field makes it possible to assign a profile to a group with the desired tags. The different available groups can be consulted in the Profiles section → Module tags.
  • Autocreate blacklist: Allows you to write a list of users, separated by commas, that will not be created automatically.
  • Active Directory server: Define here the path where our Active Directory server is located.
  • Active Directory port: To define the port number of the Active Directory server (389 by default).
  • Start TLS: Defines whether or not the Transport Layer Security (TLS) protocol will be used in communications between the client and the server.
  • Enable secondary active directory: Allows you to activate the connection to a secondary Active Directory server. It has the same fields as the primary server but also supports configuring a search expiration time (AD search timeout) with a default value of 5 seconds.
  • Double authentication: Users can choose whether to enable two-step authentication on their accounts. To learn more about how to enable two-step authentication on an account, you can read this section. This functionality requires that the server and mobile devices have a synchronized and as accurate date and time as possible.
  • In the event that there is a user password change, MS Windows® allows you to use an old password by default for 60 minutes in Active Directory. Being a Windows configuration, this behavior is totally foreign to Pandora FMS. If you wish to modify, you can consult the documentation at Microsoft® .
  • Domain: Define the domain that the Active Directory will use.
    • At this time a user's primary groups are not supported with advanced group settings in AD Authentication.
    • If you are using Advanced Configuration AD, be sure to set the full path in the domain field (Domain).
    • If the Active Directory installation is with LDAP, you must define here the LDAP path in which the server is located, generally:
  • リモートユーザの自動作成(Automatically create remote users): リモートユーザーの自動作成を有効または無効にします。 このオプションを使用すると、Pandora FMS は LDAP ユーザを使ってログインした後に自動的にユーザを作成することができます。 次の3つのフィールドは、自動作成が有効の場合にのみ表示されます。
  • パスワードの保存(Save Password): このオプションは、Pandora FMS バージョン 750 以降にあります。有効化すると、AD パスワードを Pandora FMS ローカルに保存できます。プロファイルの自動作成(Automatically create profile)
  • 高度な AD 設定(Advanced Configuration AD): このオプションを有効化すると、高度な AD 権限設定が利用されます。
    • 高度な AD 権限(Advanced Permissions AD): 新しい権限の追加 で追加された高度な権限を一覧表示します。
  • プロファイルの自動作成(Automatically create profile): ユーザの自動作成が有効になっている場合、このフィールドを使用して、自動作成されたユーザに特定のプロファイル タイプを割り当てることができます。 デフォルトのプロファイルは、Chief Operator, Group Coordinator, Operator (Read), Operator (Write) および Pandora Administrator です。プロファイル → プロファイル管理 から、さまざまなプロファイルを確認できます。
  • プロファイルグループの自動作成(Automatically create profile group): ユーザの自動作成を有効にすると、このフィールドでユーザをグループに割り当てることができます。 さまざまなグループは、プロファイル(Profiles) → エージェントグループの管理(Manage agent groups) で確認できます。
  • プロファイルタグの自動作成(Automatically create profile tags): リモートユーザの自動作成が有効な場合、このフィールドを使用して目的のタグをグループに割り当てることができます。 利用可能なさまざまなグループは、プロファイル(Profile)モジュールタグ(Module tags) で確認できます。
  • ブラックリストの自動作成(Autocreate blacklist): 自動で作成したくないユーザのカンマ区切りの一覧です。
  • アクティブディレクトリサーバ(Active directory server): ここで、Active Directory サーバが配置されているパスを定義します。
  • アクティブディレクトリポート(Active directory port): アクティブディレクトリサーバのポートです。(デフォルトは 389)
  • TLS の開始(Start TLS): クライアントとサーバの間の通信で、Transport Layer Security (TLS) プロトコルの利用を ON/OFF します。
  • セカンダリ Active Directory の有効化(Enable secondary active directory): セカンダリ Active Directory サーバへの接続を有効化できます。プライマリサーバと同じフィールドがありますが、検索有効期限 (AD 検索タイムアウト(AD search timeout)) の設定もサポートされており、デフォルト値は 5 秒です。
  • 二段階認証(Double authentication): バージョン 6.0 以降、このオプションを有効にすると、ユーザが自身のアカウントで 2段階認証を有効にできるようになりました。ユーザアカウントで 2段階認証を有効にする方法についての詳細は、こちらの章 を参照してください。この機能を使用するには、サーバーとモバイル デバイスの日付と時刻が同期され、可能な限り正確である必要があります。
  • ユーザのパスワードが変更された場合、MS Windows® では、Active Directory のデフォルトで 60 分間古いパスワードを使用できます。これは Windows の設定であるため、Pandora FMS ではまったく想定されていない動作です。変更したい場合は、Microsoft のドキュメントを参照してください。
  • ドメイン(Domain): Active Directory が使用するドメインを定義します。
    • 現時点では、ユーザのプライマリグループは AD 認証の高度なグループ設定ではサポートされていません。
    • 高度な AD 設定(Advanced Configuration AD) を使用している場合は、ドメインフィールド (ドメイン(Domain)) に必ずフルパスを設定してください。
    • Active Directory のインストールが LDAP を使用している場合は、通常、サーバが配置されている LDAP パスをここで定義する必要があります。
ldap:addc.mydomain

  • In order to use this mode, OpenLDAP dependencies must be installed.
  • Depending on the operating system used, the commands used are:
  • このモードを使用するには、OpenLDAP の依存ファイルがインストールされている必要があります。
  • 使用するオペレーティングシステムに応じて、次のようなコマンドを使用します:
yum install openldap*

Or

または

apt install ldap-utils

Important fields:

重要なフィールド:

  • LDAP server and Secondary LDAP server: Depending on the environment, the host may be accessed directly (x.x.x.x.x) or by URL (ldap://x.x.x.x.x, ldaps://x.x.x.x.x).
  • Login attribute and Secondary Login attribute: Both fields are case sensitive.
  • Fallback to local authentication: Should this option be enabled, local authentication will be performed if LDAP fails. Administrator users will always have fallback enabled, in order not to lose access to Pandora FMS in case of remote authentication system failure.
  • Automatically create remote users: It enables or disables remote user automatic creation. This option allows Pandora FMS to create the users automatically once they have logged in (login) using LDAP.
  • LDAP function: When searching LDAP, you may choose whether to use the native PHP function or the local ldapsearch command. It is recommended to use the local command for those environments that have an LDAP with many elements.
  • LDAP サーバ(LDAP server) および セカンダリ LDAP サーバ(Secondary LDAP server): 環境に応じて、ホストに対して直接アクセスする (x.x.x.x.x) ことも、URL でアクセスする (ldap://x.x.x.x.xldaps://x.x.x.x.x) こともできます。
  • ログインアトリビュート(Login attribute) および セカンダリログインアトリビュート(Secondary Login attribute): どちらのフィールドも大文字と小文字が区別されます。
  • ローカル認証にフォールバック(Fallback to local Authentication): このオプションを有効にすると、LDAPリモート認証が失敗した場合に、ローカル認証にフォールバックします。管理者ユーザは、リモート認証システムに障害が発生した場合でも Pandora FMS へのアクセスを失わないように、常にフォールバックが有効になります。
  • リモートユーザの自動作成(Autocreate remote users): リモートユーザの自動作成を有効化/無効化します。このオプションで、LDAP を使ってログインしたユーザを自動的に作成できます。
  • LDAP 機能(LDAP function): LDAP を検索するときに、PHP のネイティブ機能を使うか ldapsearch コマンドを使うかを選択できます。LDAP に多くの要素がある環境では、ローカルコマンドを利用することをお勧めします。

Advanced Config LDAP

高度な LDAP 設定

  • Should this option be enabled, a list of all saved advanced permissions will be displayed. New permissions may be added by selecting the profile, groups and tags, next to the attribute filter. If any user meets any of these attributes (e.g. a particular organizational unit or group), then the user will be created.
  • If this option is not activated, the simple system will be used for user profile creation (Automatically create profile, Automatically create profile group, Automatically create profile tags, Automatically assigned no hierarchy).
  • このオプションを有効にすると、保存されているすべての高度な権限のリストが表示されます。属性フィルターの横にあるプロファイル、グループ、タグを選択すると、新しい権限を追加できます。ユーザがこれらの属性のいずれか (特定の組織単位またはグループなど) を満たしている場合、ユーザが作成されます。
  • このオプションが有効になっていない場合は、ユーザプロファイルを作成するためのシンプルなシステムが使用されます (プロファイルを自動的に作成プロファイルグループを自動的に作成プロファイルタグを自動的に作成階層なしで自動的に割り当て)。

Attributes must have the following format Attribute_Name = Attribute_Value.

属性は次の形式である必要があります: Attribute_Name = Attribute_Value

  • Enable secondary LDAP: If you enable a secondary LDAP server as a backup, the corresponding primary LDAP server fields will appear.
  • Double authentication: Users will be able to choose whether to enable two-step authentication on their accounts. This feature requires server and mobile devices to have the most accurate date and time synchronization possible.
  • セカンダリ LDAP の有効化(Enable secondary LDAP): セカンダリ LDAP サーバをバックアップとして有効にすると、プライマリ LDAP サーバのそれぞれのフィールドが表示されます。
  • 二段階認証(Double authentication): ユーザは、自分のアカウントで 2 段階認証を有効にするかどうか を選択できます。この機能を使用するには、サーバとモバイルデバイスの日付と時刻が同期され、可能な限り正確である必要があります。

To use this feature the administrator must activate double authentication in the authentication section of Pandora FMS Web Console global configuration:

この機能を使用するには、管理者は Pandora FMS Web コンソールのグローバル設定の認証セクションで二段階認証を有効にする必要があります。

Management → Settings → System Settings → Authentication → Double authentication.

管理(Management) → セットアップ(Settings) → システム設定(System Settings) → 認証(Authentication) → 二段階認証(Double authentication)

Users may choose whether to enable two-step authentication on their accounts by accessing the Edit my user option.

ユーザは、ユーザの編集 オプションにアクセスして、自分のアカウントで 二段階認証 を有効にするかどうかを選択できます。

This feature requires for PFMS server and the mobile devices to have an accurately synchronized date and time.

この機能を使用するには、PFMS サーバモバイルデバイス の日付と時刻が正確に同期されている必要があります。

It will also be necessary to have the code generator application on a mobile device owned by each user. To find out where and how to download it:

また、各ユーザが所有するモバイルデバイスにコードジェネレーターアプリケーションをインストールする必要があります。ダウンロード場所と方法については、以下をご覧ください。

The PFMS notification system may be used to inform all users that 2FA is available and how to activate this personal option. To do this in the menu Operation → Workspace → Messages → New message you type in a message for group All similar to this one:

PFMS通知システムを使用して、2FA が利用可能であること、およびこの個人オプションを有効にする方法をすべてのユーザに通知できます。これを行うには、メニュー操作(Operation) → ワークスペース(Workspace) → メッセージ(Message) → 新規メッセージ(New message)で、グループ All 宛てに次のようなメッセージを入力します。

Force 2FA for all users is enabled

すべてのユーザに対して二段階認証を強制する(Force 2FA for all users is enabled)

Enabling this option will force all users to use the two-step authentication.

このオプションを有効にすると、すべてのユーザが 2 段階認証を使用するよう強制されます。

To disable this feature to a specific user without using the graphical interface, an administrator can use the PFMS CLI.

グラフィカルインターフェイスを使用せずにこの機能を無効にするには、管理者にて PFMS CLI を使用できます

SAML is an open XML-based authentication and authorization standard. Pandora FMS can work as a service provider with its internal SAML identity provider.

SAML は、オープンな XML ベースの認証標準です。Pandora FMS は、内部の SAML アイデンティティプロバイダを使用してサービスプロバイダとして動作できます。

Administrators always authenticate against the local database.

管理者は常にローカルデータベースに対して認証を行います。

SimpleSAMLphp 2.0 のインストール

You must download SimpleSAMLphp version 2.3.2 from its official repository:

公式リポジトリから SimpleSAMLphp バージョン 2.3.2 をダウンロードする必要があります。

and then be uploaded to the Pandora FMS server. If the PFMS server has internet access and wget is installed, you can use the following command directly in a directory with sufficient space and write permissions:

その後、Pandora FMS サーバにアップロードします。PFMS サーバがインターネットに接続でき、wget がインストールされている場合は、十分な容量と書き込み権限のあるディレクトリで以下のコマンドを直接実行できます。

wget https://github.com/simplesamlphp/simplesamlphp/releases/download/v2.3.2/simplesamlphp-2.3.2-full.tar.gz

Unzip the downloaded file with:

ダウンロードしたファイルを次のように解凍します。

tar -xvf simplesamlphp-2.3.2-full.tar.gz

The folder must be moved to its final location:

フォルダを最終的な場所に移動する必要があります。

mv simplesamlphp-2.3.2 /opt/simplesamlphp

To share access with Pandora FMS, you must create the following symbolic link:

Pandora FMS とアクセスを共有するために、次のシンボリックリンクを作成する必要があります。

ln -s /opt/simplesamlphp/public /var/www/html/simplesamlphp

SimpleSAMLphp bases its configuration on the config.php file. With the final location established above, the default template must be renamed:

SimpleSAMLphpconfig.php ファイルにて設定を行います。上記の最終的な場所が決まったら、デフォルトのテンプレートの名前を変更する必要があります。

mv /opt/simplesamlphp/config/config.php.dist /opt/simplesamlphp/config/config.php

This will give you the complete path to the configuration file in:

これにより、次の設定ファイルが用意されます。

/opt/simplesamlphp/config/config.php

The following values must be edited using your favorite text editor (note that you must change “pandora.local” to the URL of the PFMS web console and keep the comma at the end of the line as it is part of the instruction blocks):

以下の値は、お好みのテキストエディタを使用して編集する必要があります (“pandora.local” を PFMS Web コンソールの URL に変更し、行末のカンマは命令ブロックの一部であるため、そのままにしておく必要があることに注意してください)。

/opt/simplesamlphp/config/config.php
'baseurlpath' => 'https://pandora.local/simplesamlphp/',
'auth.adminpassword' => '123pandora',

Save the changes to the file and exit to the command line.

ファイルへの変更を保存し、コマンドラインに戻ります。

If a cache permission error appears, apply the following:

mkdir /var/cache/simplesamlphp && chown apache:apache /var/cache/simplesamlphp


キャッシュパーミッションエラーが表示された場合は、以下を適用してください。

mkdir /var/cache/simplesamlphp && chown apache:apache /var/cache/simplesamlphp


This will get SimpleSAMLphp up and running, and it should display the home page at the URL https://pandora.local/simplesamlphp/ (replace pandora.local with the URL of the PFMS web console).

これにより、SimpleSAMLphp が起動して実行され、URL https://pandora.local/simplesamlphp/ のホームページが表示されます (pandora.local を PFMS Web コンソールの URL に置き換えます)。

If you connect via HTTP instead of HTTPS, authentication will fail until the Apache web server is configured to listen on the secure port 443.

HTTPS ではなく HTTP 経由で接続すると、Apache Web サーバがセキュアポート 443listen するように設定されるまで認証は失敗します。

To access the administration of SimpleSAMLphp, you must first rename the file. authsources.php.dist:

SimpleSAMLphp の管理にアクセスするには、まずファイルの名前を変更する必要があります。 authsources.php.dist:

mv /opt/simplesamlphp/config/authsources.php.dist /opt/simplesamlphp/config/authsources.php

It can be accessed via the URL https://pandora.local/simplesamlphp/admin/ (replace pandora.local with the URL of the PFMS web console):

URL https://pandora.local/simplesamlphp/admin/ からアクセスできます (pandora.local を PFMS Web コンソールの URL に置き換えます)。

Configuring Pandora FMS with SAML

Management → Setup → Setup → Authentication menu.






The following values are common:

Some notable fields:

  • SAML group name attribute: SAML field where to search for the group name (while auto-create remote users is enabled).
  • SimpleSAML path: Directory where the folder is located simplesamlphp.
  • SAML source: Name authsource, for example example-userpass.
  • SAML email attribute: SAML field where to search for the user's email address (while auto-create remote users is enabled)

Before configuring any third-party services with SAML, it is recommended to test and verify locally the installation of SimpleSAMLphp.

Configuring Azure with SAML

In Azure® services, you must access the Extra ID section:

Then go to Business Applications:

A new application is created (or an existing one is used):

Single sign-on access:

Edit the basic SAML configuration:

Fill in the following fields with the ID for the application, the address of the installed SimpleSAMLphp (replace “pandora.local” with the URL of the PFMS web console) and the address to which Azure® will redirect when the session is closed:

Download the XML file with federation metadata, which will be used later:

Finally, save the ID from the previous step and the URL of the extra identifier:

Configuration in SimpleSAMLphp

The file /opt/simplesamlphp/config/authsources.php must be edited with the following values:

And on the SimpleSAMLphp website, go to the Federation menu and then to the Tools section for converting XML to PHP:

The name saml20-idp-remote.php.dist must be changed to:

mv /opt/simplesamlphp/metadata/saml20-idp-remote.php.dist /opt/simplesamlphp/metadata/saml20-idp-remote.php

Copy the contents of the previously downloaded XML file, paste it, and process it. This will generate a configuration text for PHP, which you should copy and paste into the file /opt/simplesamlphp/config/authsources.php, replacing all of its contents.

If everything is correct, proceed to perform a test:

Obtaining the following result:

The email address and user ID can be taken from the attributes returned by Azure® in the test performed above:

For advanced configuration, you can delve deeper into the mapping of properties or select a default one if none match:

Pandora FMS allows to encrypt the passwords stored in the database.

The encryption key is generated from a user-supplied password and is not stored in the database (neither the password nor the key), so that passwords cannot be recovered from a database dump.

Once the user sets the password, the encryption works transparently to the user.

If the password provided by the user is lost, you will not be able to recover the passwords stored in the Pandora FMS database. Save in a safe place or make a backup of the config.php and pandora_server.conf files.

Passwords are encrypted using the Rijndael cipher with 128-bit blocks in ECB mode. A 256-bit key is generated at startup from the MD5 of the password set by the user.

To enable key encryption, the password must be configured both in the Pandora FMS Server and in the Web Console.

The steps to follow for encryption are as follows:

  • Stop the server, both in Command Center (Metaconsole) and in the nodes.
  • Update the encryption_passphrase fields in /etc/pandora/pandora_server.conf and /var/www/html/pandora_console/include/config.php, both in Command Center (Metaconsole) and in nodes.
$config["encryption_passphrase"]="your encryption passphrase";
  • Launch the encryption script both in Command Center (Metaconsole) and in the nodes.
/usr/bin/pandora_encrypt_db /etc/pandora/pandora_server.conf

The Pandora FMS server should be restarted after making the changes and launching the script.

It is possible to change the encryption password in case it has been compromised. You must first decrypt the passwords stored in the database:

/usr/bin/pandora_encrypt_db -d /etc/pandora/pandora_server.conf

Then, after having changed the encryption password (as described in the section for configuration in a new installation), you can encrypt it again:

/usr/bin/pandora_encrypt_db /etc/pandora/pandora_server.conf

From 7.0 NG 739 onwards, the secure credential manager is included. Please refer to the following section to finish this process correctly.

Credential store:

If you have an encrypted database, in order to continue using the credential manager without losing data decrypt everything except the tcredential_store table.

To do so, execute the following commands:

/usr/bin/pandora_encrypt_db -d -c /etc/pandora/pandora_server.conf

It will be deciphered.

Once decrypted, it will be re-encrypted again:

/usr/bin/pandora_encrypt_db /etc/pandora/pandora_server.conf

If you only want to encrypt from scratch, just execute the last command.

It is recommended to keep every password stored in Pandora FMS encrypted.

  • Stop the server, both in Command Center (Metaconsole) and in the nodes.
  • Launch the decryption script both in Command Center (Metaconsole) and in the nodes.
/usr/bin/pandora_encrypt_db -d /etc/pandora/pandora_server.conf
  • Comment encryption_passphrase in /etc/pandora/pandora_server.conf and /var/www/html/pandora_console/include/config.php both in Command Center (Metaconsole) and in nodes.
# $config["encryption_passphrase"]="your encryption passphrase";

The Pandora FMS server should be restarted after making the changes and launching the script.

Management → Setup → Setup → Password policy menu.






To activate the password policy, you must have an administrator profile (Pandora administrator) or be a superadmin.

Important fields:

  • Enable password policy: Deactivated by default.
  • Min. password size: By default four characters.
  • Password expiration: By default zero 0 days (no expiration).
  • Block user if login fails: Minutes that the user remains blocked if the maximum number of failed attempts is consumed, by default 5 minutes.
  • Number of failed login attempts: By default 5 attempts.
  • Enable password history and Compare previous password: They work together to prevent a user from using repeated passwords. The first token must be enabled and the second token must be greater than zero (default 3), so that a user's new password will be compared with the 3 previously used by the same user (or the number of times indicated).
  • The password must include numbers: The password must include numbers, disabled by default.
  • The password must include symbols: The password must include symbols, disabled by default.
  • Force password change on first login: Force password change on first login after user creation, disabled by default.
  • Apply password policy to admin users: Applies the password policy also to administrator users, activated by default.
  • Exclusion list for passwords: Allows you to add a list of passwords explicitly excluded from use in Pandora FMS.

Management → Admin tools → System Audit Log menu.






Pandora FMS keeps a log with all the changes and actions of importance produced in the Pandora FMS Console. There you will see a series of entries related to the Console activity, information about the user, type of action, date and a short description of the registered events.

You can filter which entries to display by different criteria, including: actions, user and IP address. You can even perform a text search and determine the maximum hours to be searched, with the option to save the filter if it is frequently used.

Pandora FMS ドキュメント一覧に戻る

  • ja/documentation/pandorafms/cybersecurity/07_safety_functions.1756593602.txt.gz
  • 最終更新: 2025/08/30 22:40
  • by junichi