[pkg-nagios-changes] [Git][nagios-team/pkg-icingaweb2][master] 4 commits: New upstream version 2.9.6
Bas Couwenberg (@sebastic)
gitlab at salsa.debian.org
Tue Mar 8 15:13:36 GMT 2022
Bas Couwenberg pushed to branch master at Debian Nagios Maintainer Group / pkg-icingaweb2
Commits:
d6e6c0fc by Bas Couwenberg at 2022-03-08T16:00:05+01:00
New upstream version 2.9.6
- - - - -
bfff9fe6 by Bas Couwenberg at 2022-03-08T16:01:03+01:00
Update upstream source from tag 'upstream/2.9.6'
Update to upstream version '2.9.6'
with Debian dir d081086ff4c169f339d5e6a09bfae34dd13579db
- - - - -
1dfc30f7 by Bas Couwenberg at 2022-03-08T16:01:50+01:00
New upstream release.
- - - - -
59e903d5 by Bas Couwenberg at 2022-03-08T16:02:58+01:00
Set distribution to unstable.
- - - - -
26 changed files:
- CHANGELOG.md
- VERSION
- application/VERSION
- application/forms/Config/Resource/SshResourceForm.php
- debian/changelog
- doc/02-Installation.md
- + doc/02-Installation.md.d/01-Debian.md
- + doc/02-Installation.md.d/02-Ubuntu.md
- + doc/02-Installation.md.d/03-CentOS.md
- + doc/02-Installation.md.d/04-RHEL.md
- + doc/02-Installation.md.d/05-SLES.md
- + doc/02-Installation.md.d/06-Amazon-Linux.md
- + doc/02-Installation.md.d/07-From-Source.md
- doc/20-Advanced-Topics.md
- library/Icinga/Application/Version.php
- library/Icinga/Web/Controller/StaticController.php
- modules/doc/module.info
- modules/migrate/module.info
- modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcontactQuery.php
- modules/monitoring/library/Monitoring/Backend/Ido/Query/HostserviceproblemsummaryQuery.php
- modules/monitoring/library/Monitoring/Backend/Ido/Query/IdoQuery.php
- modules/monitoring/library/Monitoring/Backend/Ido/Query/ServicecontactQuery.php
- modules/monitoring/module.info
- modules/setup/module.info
- modules/test/module.info
- modules/translation/module.info
Changes:
=====================================
CHANGELOG.md
=====================================
@@ -4,6 +4,20 @@ Please make sure to always read our [Upgrading](doc/80-Upgrading.md) documentati
## What's New
+### What's New in Version 2.9.6
+
+**Notice**: This is a security release. It is recommended to upgrade immediately.
+
+#### Security Fixes
+
+This release includes three security related fixes. The first is a path traversal issue that affects installations
+of v2.9.0 and above. Another one allows admins to run arbitrary PHP code just by accessing the UI. The last one may
+disclose unwanted details to restricted users. Please check the advisories on GitHub for more details.
+
+* Path traversal in static library file requests for unauthenticated users [GHSA-5p3f-rh28-8frw](https://github.com/Icinga/icingaweb2/security/advisories/GHSA-5p3f-rh28-8frw)
+* SSH resources allow arbitrary code execution for authenticated users [GHSA-v9mv-h52f-7g63](https://github.com/Icinga/icingaweb2/security/advisories/GHSA-v9mv-h52f-7g63)
+* Unwanted disclosure of hosts and related data, linked to decommissioned services [GHSA-qcmg-vr56-x9wf](https://github.com/Icinga/icingaweb2/security/advisories/GHSA-qcmg-vr56-x9wf)
+
### What's New in Version 2.9.5
This is a hotfix release which fixes the following issues:
=====================================
VERSION
=====================================
@@ -1 +1 @@
-v2.9.5
+v2.9.6
=====================================
application/VERSION
=====================================
@@ -1 +1 @@
-053971c99dc1a4510beb64a888ea695cc14032dc 2021-11-18 10:48:44 +0100
+e702d933e15b0907628091a03741baff1b6074df 2022-03-08 12:14:03 +0100
=====================================
application/forms/Config/Resource/SshResourceForm.php
=====================================
@@ -52,9 +52,13 @@ class SshResourceForm extends Form
if ($this->getRequest()->getActionName() != 'editresource') {
$callbackValidator = new Zend_Validate_Callback(function ($value) {
- if (openssl_pkey_get_private($value) === false) {
+ if (
+ substr(ltrim($value), 0, 7) === 'file://'
+ || openssl_pkey_get_private($value) === false
+ ) {
return false;
}
+
return true;
});
$callbackValidator->setMessage(
@@ -126,20 +130,19 @@ class SshResourceForm extends Form
$configDir = Icinga::app()->getConfigDir();
$user = $form->getElement('user')->getValue();
- $filePath = $configDir . '/ssh/' . $user;
-
+ $filePath = join(DIRECTORY_SEPARATOR, [$configDir, 'ssh', sha1($user)]);
if (! file_exists($filePath)) {
$file = File::create($filePath, 0600);
} else {
$form->error(
- sprintf($form->translate('The private key for the user "%s" is already exists.'), $user)
+ sprintf($form->translate('The private key for the user "%s" already exists.'), $user)
);
return false;
}
$file->fwrite($form->getElement('private_key')->getValue());
- $form->getElement('private_key')->setValue($configDir . '/ssh/' . $user);
+ $form->getElement('private_key')->setValue($filePath);
return true;
}
=====================================
debian/changelog
=====================================
@@ -1,3 +1,10 @@
+icingaweb2 (2.9.6-1) unstable; urgency=medium
+
+ * Team upload.
+ * New upstream release.
+
+ -- Bas Couwenberg <sebastic at debian.org> Tue, 08 Mar 2022 16:02:48 +0100
+
icingaweb2 (2.9.5-1) unstable; urgency=medium
* Team upload.
=====================================
doc/02-Installation.md
=====================================
@@ -1,29 +1,14 @@
+<!-- {% if index %} -->
# Installation <a id="installation"></a>
The preferred way of installing Icinga Web 2 is to use the official package repositories depending on which operating
system and distribution you are running.
-In case you are upgrading from an older version of Icinga Web 2
-please make sure to read the [upgrading](80-Upgrading.md#upgrading) section
-thoroughly.
+Please follow the steps listed for your operating system. Packages for distributions other than the ones
+listed here may also be available. Please refer to [icinga.com/get-started/download](https://icinga.com/get-started/download/#community)
+for a full list of available community repositories.
-Source and automated setups are described inside the [advanced topics](20-Advanced-Topics.md#advanced-topics)
-chapter.
-
-## Installing Requirements <a id="installing-requirements"></a>
-
-* [Icinga 2](https://icinga.com/products/icinga-2/) with the IDO database backend (MySQL or PostgreSQL)
-* A web server, e.g. Apache or Nginx
-* PHP version >= 7.3
- * Older versions (5.6+) are only supported up until version 2.11
-* [Icinga PHP Library (ipl)](https://github.com/Icinga/icinga-php-library) (>= 0.6)
-* [Icinga PHP Thirdparty](https://github.com/Icinga/icinga-php-thirdparty) (>= 0.10)
-* The following PHP modules must be installed: cURL, json, gettext, fileinfo, intl, dom, OpenSSL and xml
-* For exports to PDF also the following PHP modules are required: mbstring, GD, Imagick
-* LDAP PHP library when using Active Directory or LDAP for authentication
-* MySQL or PostgreSQL PHP libraries
-
-### Browser Support
+## Browser Support
Icinga Web 2 and modules made by Icinga don't require a particular browser or set of browsers. The
vendor of the browser in question doesn't matter much. However, the features a browser supports do.
@@ -38,43 +23,37 @@ or sub-category here:
If your desired browser and its version is showing up in green when visiting the respective link,
it's probably okay to use it for Icinga Web 2.
-> **Note for Internet Explorer users**
->
-> Support for Internet Explorer will be completely dropped with version 2.11
+!!! note
-## Installing Icinga Web 2 from Package <a id="installing-from-package"></a>
+ Support for Internet Explorer will be completely dropped with version 2.11
-Official repositories ([support matrix](https://icinga.com/subscription/support-details/)):
-
-| Distribution | Repository |
-| ------------- | ---------- |
-| Debian | [Icinga Repository](https://packages.icinga.com/debian/) |
-| Ubuntu | [Icinga Repository](https://packages.icinga.com/ubuntu/) |
-| RHEL/CentOS | [Icinga Repository](https://packages.icinga.com/epel/) |
-| openSUSE | [Icinga Repository](https://packages.icinga.com/openSUSE/) |
-| SLES | [Icinga Repository](https://packages.icinga.com/SUSE/) |
+## Upgrade <a id="upgrade"></a>
+In case you are upgrading from an older version of Icinga Web 2
+please make sure to read the [upgrading](80-Upgrading.md#upgrading) section
+thoroughly.
+<!-- {% elif not from_source %} -->
-Community repositories:
+## Installation Requirements <a id="installation-requirements"></a>
-| Distribution | Repository |
-| ------------- | ---------- |
-| Gentoo | [Upstream](https://packages.gentoo.org/packages/www-apps/icingaweb2) |
-| FreeBSD | [Upstream](http://portsmon.freebsd.org/portoverview.py?category=net-mgmt&portname=icingaweb2) |
-| ArchLinux | [Upstream](https://aur.archlinux.org/packages/icingaweb2) |
-| Alpine Linux | [Upstream](https://git.alpinelinux.org/cgit/aports/tree/community/icingaweb2/APKBUILD) |
+* [Icinga 2](https://icinga.com/products/icinga-2/) with the IDO database backend (MySQL or PostgreSQL)
+* A web server, e.g. Apache or Nginx
+* PHP version >= 7.3
+ * Older versions (5.6+) are only supported up until Icinga Web v2.11
-Packages for distributions other than the ones listed above may also be available.
-Please contact your distribution packagers.
+### Optional Requirements
+* For exports to PDF also the following PHP modules are required: mbstring, GD, Imagick
+* LDAP PHP library when using Active Directory or LDAP for authentication
-### Setting up Package Repositories <a id="package-repositories"></a>
+## Add Icinga Package Repository <a id="add-icinga-package-repository"></a>
You need to add the Icinga repository to your package management configuration for installing Icinga Web 2.
If you've already configured your OS to use the Icinga repository for installing Icinga 2, you may skip this step.
-**Debian**:
+<!-- {% if debian %} -->
+### Debian Repository <a id="ubuntu-repository"></a>
-```
+```bash
apt-get update
apt-get -y install apt-transport-https wget gnupg
@@ -88,10 +67,12 @@ DIST=$(awk -F"[)(]+" '/VERSION=/ {print $2}' /etc/os-release); \
apt-get update
```
+<!-- {% endif %} -->
-**Ubuntu**:
+<!-- {% if ubuntu %} -->
+### Ubuntu Repository <a id="ubuntu-repository"></a>
-```
+```bash
apt-get update
apt-get -y install apt-transport-https wget gnupg
@@ -105,76 +86,55 @@ wget -O - https://packages.icinga.com/icinga.key | apt-key add -
apt-get update
```
+<!-- {% endif %} -->
-**RHEL and CentOS 8**:
-```
-dnf install https://packages.icinga.com/epel/icinga-rpm-release-8-latest.noarch.rpm
-```
+<!-- {% if centos %} -->
+### CentOS Repository <a id="centos-repository"></a>
-**RHEL and CentOS 7**:
-```
-yum install https://packages.icinga.com/epel/icinga-rpm-release-7-latest.noarch.rpm
+```bash
+rpm --import https://packages.icinga.com/icinga.key
+wget https://packages.icinga.com/centos/ICINGA-release.repo -O /etc/yum.repos.d/ICINGA-release.repo
```
-**Fedora 31**:
-```
-dnf install https://packages.icinga.com/fedora/icinga-rpm-release-31-latest.noarch.rpm
-```
-
-**SLES 15/12**:
-```
-zypper ar http://packages.icinga.com/SUSE/ICINGA-release.repo
-zypper ref
-```
+The packages for CentOS depend on other packages which are distributed
+as part of the [EPEL repository](https://fedoraproject.org/wiki/EPEL).
-If you're using php-fpm on SLES 15 SP2 onwards, `/etc/icingaweb2` may not be writable.
-That's because the default systemd unit file for php-fpm has `ProtectSystem=full`
-enabled. You want to lookup/add the systemd setting `ReadWritePaths=` in this case and
-add `/etc/icingaweb2` to it. Alternatively you can also define a different configuration
-directory using the environment variable `ICINGAWEB_CONFIGDIR`.
+CentOS 7:
-**openSUSE**:
-```
-zypper ar http://packages.icinga.com/openSUSE/ICINGA-release.repo
-zypper ref
+```bash
+yum install epel-release
```
-**Alpine Linux**:
-```
-echo "http://dl-cdn.alpinelinux.org/alpine/edge/community" >> /etc/apk/repos
-apk update
+Since Icinga Web v2.5 we also require a **newer PHP version** than what is available
+in RedHat itself. You need to enable the SCL repository, so that the dependencies
+can pull in the newer PHP.
+
+```bash
+yum install centos-release-scl
```
-> INFO
->
-> Latest version of Icinga Web 2 is in the edge repository, which is the -dev branch.
+<!-- {% endif %} -->
-#### RHEL/CentOS Notes <a id="package-repositories-rhel-notes"></a>
+<!-- {% if rhel %} -->
+### RHEL Repository <a id="rhel-repository"></a>
-The packages for RHEL/CentOS depend on other packages which are distributed
-as part of the [EPEL repository](https://fedoraproject.org/wiki/EPEL).
+!!! info
-CentOS 8 additionally needs the PowerTools repository for EPEL:
-*Be aware that the name of the `powertools` repo [changed to lowercase](https://wiki.centos.org/Manuals/ReleaseNotes/CentOS8.2011#Yum_repo_file_and_repoid_changes) with CentOS 8.3.2011 and newer.*
-*If you are using CentOS 8.2.2044 or earlier please change the name to `PowerTools` in the following command.*
-```
-dnf install 'dnf-command(config-manager)'
-dnf config-manager --set-enabled powertools
+ A paid repository subscription is required for RHEL repositories. Get more information on
+ [icinga.com/subscription](https://icinga.com/subscription)
-dnf install epel-release
-```
-
-CentOS 7:
+ Don't forget to fill in the username and password section with your credentials in the local .repo file.
-```
-yum install epel-release
+```bash
+rpm --import https://packages.icinga.com/icinga.key
+wget https://packages.icinga.com/subscription/rhel/ICINGA-release.repo -O /etc/yum.repos.d/ICINGA-release.repo
```
If you are using RHEL you need to additionally enable the `optional` and `codeready-builder`
repository before installing the [EPEL rpm package](https://fedoraproject.org/wiki/EPEL#How_can_I_use_these_extra_packages.3F).
-RHEL 8:
+#### RHEL 8
-```
+```bash
ARCH=$( /bin/arch )
subscription-manager repos --enable rhel-8-server-optional-rpms
@@ -183,273 +143,389 @@ subscription-manager repos --enable "codeready-builder-for-rhel-8-${ARCH}-rpms"
dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
```
-RHEL 7:
+#### RHEL 7
+Since Icinga Web v2.5 we also require a **newer PHP version** than what is available
+in RedHat itself. You need to enable the SCL repository, so that the dependencies
+can pull in the newer PHP.
-```
+```bash
subscription-manager repos --enable rhel-7-server-optional-rpms
+subscription-manager repos --enable rhel-server-rhscl-7-rpms
+
yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
```
+<!-- {% endif %} -->
-##### RHEL/CentOS 7 PHP SCL
+<!-- {% if sles %} -->
+### SLES Repository <a id="rhel-repository"></a>
-Since version 2.5.0 we also require a **newer PHP version** than what is available
-in RedHat itself. You need to enable the SCL repository, so that the dependencies
-can pull in the newer PHP.
+!!! info
-CentOS:
-```
-yum install centos-release-scl
+ A paid repository subscription is required for RHEL repositories. Get more information on
+ [icinga.com/subscription](https://icinga.com/subscription)
+
+ Don't forget to fill in the username and password section with your credentials in the local .repo file.
+
+```bash
+rpm --import https://packages.icinga.com/icinga.key
+
+zypper ar https://packages.icinga.com/subscription/sles/ICINGA-release.repo
+zypper ref
```
-RedHat:
+You need to additionally enable a couple of SLES repositories to fulfill dependencies:
+
+```bash
+source /etc/os-release
+
+SUSEConnect -p sle-module-desktop-applications/$VERSION_ID/x86_64
+SUSEConnect -p sle-module-development-tools/$VERSION_ID/x86_64
+SUSEConnect -p sle-module-web-scripting/$VERSION_ID/x86_64
+SUSEConnect -p PackageHub/$VERSION_ID/x86_64
```
-subscription-manager repos --enable rhel-server-rhscl-7-rpms
+<!-- {% endif %} -->
+
+<!-- {% if amazon_linux %} -->
+### Amazon Linux 2 Repository <a id="amazon-linux-2-repository"></a>
+
+!!! info
+
+ A paid repository subscription is required for Amazon Linux repositories. Get more information on
+ [icinga.com/subscription](https://icinga.com/subscription)
+
+ Don't forget to fill in the username and password section with your credentials in the local .repo file.
+
+```bash
+rpm --import https://packages.icinga.com/icinga.key
+wget https://packages.icinga.com/subscription/amazon/ICINGA-release.repo -O /etc/yum.repos.d/ICINGA-release.repo
```
-Make sure to also read the chapter on [Setting up FPM](02-Installation.md#setting-up-fpm).
+You need to install and enable the `amazon-linux-extras` repository to meet the requirements of
+Icinga Web 2 on Amazon Linux 2:
-#### Alpine Linux Notes <a id="package-repositories-alpine-notes"></a>
+```bash
+yum install -y amazon-linux-extras
-The example provided suppose that you are running Alpine edge, which is the -dev branch and is a rolling release.
-If you are using a stable version, in order to use the latest Icinga Web 2 version you should "pin" the edge repository.
-In order to correctly manage your repository, please follow
-[these instructions](https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management).
+amazon-linux-extras enable php8.0
+```
+<!-- {% endif %} -->
-### Installing Icinga Web 2 <a id="installing-from-package-example"></a>
+## Install Icinga Web 2 <a id="install-icingaweb2"></a>
You can install Icinga Web 2 by using your distribution's package manager to install the `icingaweb2` package.
-Below is a list with examples for various distributions. The additional package `icingacli` is necessary to follow further steps in this guide.
-The additional package `libapache2-mod-php` is necessary on Ubuntu to make
-Icinga Web 2 working out-of-the-box if you aren't sure or don't care about [PHP
-FPM](02-Installation.md#setting-up-fpm).
+The additional package `icingacli` is necessary to follow further steps in this guide.
-**Debian**:
-```
+<!-- {% if debian %} -->
+<!-- {% if not icingaDocs %} -->
+#### Debian
+<!-- {% endif %} -->
+```bash
apt-get install icingaweb2 icingacli
```
+<!-- {% endif %} -->
-**Ubuntu**:
-```
+<!-- {% if ubuntu %} -->
+<!-- {% if not icingaDocs %} -->
+#### Ubuntu
+<!-- {% endif %} -->
+```bash
apt-get install icingaweb2 libapache2-mod-php icingacli
```
-**RHEL/CentOS 8 and Fedora**:
+The additional package `libapache2-mod-php` is necessary on Ubuntu to automatically
+install a web server and PHP and make Icinga Web 2 work out-of-the-box.
+<!-- {% endif %} -->
+
+<!-- {% if centos or rhel or amazon_linux %} -->
+!!! tip
+
+ If you have [SELinux](90-SELinux.md) enabled, the package `icingaweb2-selinux` is also required.
+<!-- {% endif %} -->
+
+<!-- {% if centos %} -->
+<!-- {% if not icingaDocs %} -->
+#### CentOS
+<!-- {% endif %} -->
```
dnf install icingaweb2 icingacli
```
+<!-- {% endif %} -->
-**RHEL/CentOS 7**
+<!-- {% if rhel %} -->
+<!-- {% if not icingaDocs %} -->
+#### RHEL
+<!-- {% endif %} -->
+#### RHEL 8
+```bash
+dnf install icingaweb2 icingacli
```
+
+#### RHEL 7
+```bash
yum install icingaweb2 icingacli
```
+<!-- {% endif %} -->
-If you have [SELinux](90-SELinux.md) enabled, the package `icingaweb2-selinux` is also required.
-For RHEL/CentOS please read the [package repositories notes](02-Installation.md#package-repositories-rhel-notes).
-
-**SLES and openSUSE**:
-```
+<!-- {% if sles %} -->
+<!-- {% if not icingaDocs %} -->
+#### SLES
+<!-- {% endif %} -->
+```bash
zypper install icingaweb2 icingacli
```
+<!-- {% endif %} -->
-**Alpine Linux**:
-```
-apk add icingaweb2
+<!-- {% if amazon_linux %} -->
+<!-- {% if not icingaDocs %} -->
+#### Amazon Linux 2
+<!-- {% endif %} -->
+```bash
+yum install icingaweb2 icingacli
```
-For Alpine Linux please read the [package repositories notes](02-Installation.md#package-repositories-alpine-notes).
+<!-- {% endif %} -->
-## Installing the web server <a id="installing-the-web-server"></a>
+## Install the Web Server <a id="install-the-web-server"></a>
-Depending on your OS you might have to install, and or configure the web server.
-We usually only require PHP as hard dependency.
+Make sure you have a web server with PHP up and running before moving on.
+Please refer to the [installation requirements](#installation-requirements) for details about supported versions.
+Depending on your OS you might have to install, and configure the web server separately.
-We usually build on Apache httpd as the default web server, but you also can use nginx.
+## Prepare Web Setup <a id="prepare-web-setup-from-package"></a>
-**RedHat / CentOS / Fedora**
+You can set up Icinga Web 2 quickly and easily with the Icinga Web 2 setup wizard which is available the first time
+you visit Icinga Web 2 in your browser. When using the web setup you are required to authenticate using a token.
+In order to generate a token use the `icingacli`:
-Make sure to install httpd, start and enable it on boot.
+```bash
+icingacli setup token create
```
-yum install httpd
-systemctl start httpd.service
-systemctl enable httpd.service
+In case you do not remember the token you can show it using the `icingacli`:
+
+```bash
+icingacli setup token show
```
-Note for **EPEL 7 and 8**: Check the [Setting up FPM](02-Installation.md#setting-up-fpm) chapter.
+<!-- {% if debian or ubuntu %} -->
+You need to manually create a database and a database user prior to starting the web wizard.
+This is due to local security restrictions whereas the web wizard cannot create a database/user through
+a local unix domain socket.
-**SUSE SLE / openSUSE**
+```bash
+MariaDB [mysql]> CREATE DATABASE icingaweb2;
-Make sure that web server is installed, and the required modules are loaded.
+MariaDB [mysql]> GRANT ALL ON icingaweb2.* TO icingaweb2 at localhost IDENTIFIED BY 'CHANGEME';
```
-zypper install apache2
-a2enmod rewrite
-a2enmod php7
+You may also create a separate administrative account with all privileges instead.
-systemctl start apache2.service
-systemctl enable apache2.service
-```
+!!! note
-**Debian / Ubuntu**
+ This is only required if you are using a local database as authentication type.
+<!-- {% endif %} -->
-Your web server should be up and running after the installation of Icinga Web 2.
+### Start Web Setup <a id="start-web-setup-from-package"></a>
-### Setting up FPM <a id="setting-up-fpm"></a>
+Finally visit Icinga Web 2 in your browser to access the setup wizard and complete the installation:
+`/icingaweb2/setup`.
-If you are on CentOS / RedHat, or just want to run Icinga Web 2 with PHP-FPM instead
-of the Apache module.
+<!-- {% if debian or ubuntu %} -->
+!!! hint
-| Operating System | FPM configuration path |
-|---------------------|-----------------------------------|
-| RedHat 8 | `/etc/php-fpm.d/` |
-| RedHat 7 (with SCL) | `/etc/opt/rh/rh-php71/php-fpm.d/` |
-| Fedora | `/etc/php-fpm.d/` |
-| Debian/Ubuntu | `/etc/php*/*/fpm/pool.d/` |
+ Use the same database, user and password details created above when asked.
+<!-- {% endif %} -->
-The default pool `www` should be sufficient for Icinga Web 2.
+The setup wizard automatically detects the required packages. In case one of them is missing,
+e.g. a PHP module, please install the package, restart your webserver and reload the setup page.
-On RedHat you need to start and enable the FPM service.
+<!-- {% if sles %} -->
+!!! note
-RedHat / CentOS 8 and Fedora:
+ If you're using php-fpm on SLES 15 SP2 onwards, `/etc/icingaweb2` may not be writable.
+ That's because the default systemd unit file for php-fpm has `ProtectSystem=full`
+ enabled. You want to lookup/add the systemd setting `ReadWritePaths=` in this case and
+ add `/etc/icingaweb2` to it. Alternatively you can also define a different configuration
+ directory using the environment variable `ICINGAWEB_CONFIGDIR`.
+<!-- {% endif %} -->
-```
-systemctl start php-fpm.service
-systemctl enable php-fpm.service
-```
+<!-- {% if centos or rhel or amazon_linux %} -->
+!!! note
-RedHat / CentOS 7 (SCL package):
-```
-systemctl start rh-php71-php-fpm.service
-systemctl enable rh-php71-php-fpm.service
-```
+ If you have SELinux enabled, please ensure to either have the selinux package for Icinga Web 2 installed, or disable it.
+<!-- {% endif %} -->
-All module packages for PHP have this SCL prefix, so you can install a
-database module like this:
-```
-yum install rh-php71-php-mysqlnd
-# or
-yum install rh-php71-php-pgsql
-```
+<!-- {% else %} --><!-- {# end from_source elif #} -->
+<!-- {% if not icingaDocs %} -->
+## Installing Icinga Web 2 from Source <a id="installing-from-source"></a>
+<!-- {% endif %} -->
-Depending on your web server installation, we might have installed or
-updated the config file for icingaweb2 with defaults for FPM.
+Although the preferred way of installing Icinga Web 2 is to use packages, it is also possible to install Icinga Web 2
+directly from source.
-Check `/etc/httpd/conf.d/icingaweb2.conf` or `/etc/apache2/conf.d/icingaweb2.conf`.
-And `*.rpm*` `*.dpkg*` files there with updates.
+### Getting the Source <a id="getting-the-source"></a>
-Make sure that the `FilesMatch` part is included for Apache >= 2.4. For Apache < 2.4 you have to include the
-`LocationMatch` block.
+First of all, you need to download the sources.
-Also see the example from icingacli:
-```
-icingacli setup config webserver apache
+Git clone:
+
+```bash
+cd /usr/share/
+git clone https://github.com/Icinga/icingaweb2.git icingaweb2
```
-### Preparing Web Setup <a id="preparing-web-setup-from-package"></a>
+Tarball download (latest [release](https://github.com/Icinga/icingaweb2/releases/latest)):
-You can set up Icinga Web 2 quickly and easily with the Icinga Web 2 setup wizard which is available the first time
-you visit Icinga Web 2 in your browser. When using the web setup you are required to authenticate using a token.
-In order to generate a token use the `icingacli`:
-```
-icingacli setup token create
+```bash
+cd /usr/share
+wget https://github.com/Icinga/icingaweb2/archive/v2.9.5.zip
+unzip v2.9.5.zip
+mv icingaweb2-2.9.5 icingaweb2
```
-In case you do not remember the token you can show it using the `icingacli`:
-```
-icingacli setup token show
-```
+### Installing Requirements from Source <a id="installing-from-source-requirements"></a>
-#### Preparing Web Setup on Debian/Ubuntu <a id="preparing-web-setup-from-package-debian"></a>
+You will need to install certain dependencies depending on your setup:
-On Debian and derivates, you need to manually create a database and a database user prior to starting the web wizard.
-This is due to local security restrictions whereas the web wizard cannot create a database/user through
-a local unix domain socket.
+* [Icinga 2](https://icinga.com/products/icinga-2/) with the IDO database backend (MySQL or PostgreSQL)
+* A web server, e.g. Apache or Nginx
+* PHP version >= 7.3
+ * Older versions (5.6+) are only supported up until version 2.11
+* [Icinga PHP Library (ipl)](https://github.com/Icinga/icinga-php-library) (>= 0.6)
+* [Icinga PHP Thirdparty](https://github.com/Icinga/icinga-php-thirdparty) (>= 0.10)
+* The following PHP modules must be installed: cURL, json, gettext, fileinfo, intl, dom, OpenSSL and xml
+* For exports to PDF also the following PHP modules are required: mbstring, GD, Imagick
+* LDAP PHP library when using Active Directory or LDAP for authentication
+* MySQL or PostgreSQL PHP libraries
-```
-MariaDB [mysql]> CREATE DATABASE icingaweb2;
+The following example installs Apache2 as web server, MySQL as RDBMS and uses the PHP adapter for MySQL.
+Adopt the package requirements to your needs (e.g. adding ldap for authentication) and distribution.
-MariaDB [mysql]> GRANT ALL ON icingaweb2.* TO icingaweb2 at localhost IDENTIFIED BY 'CHANGEME';
+Example for RHEL/CentOS/Fedora:
+
+```bash
+yum install httpd mysql-server
+yum install php php-gd php-intl
```
-You may also create a separate administrative account with all privileges instead.
+The setup wizard will check the pre-requisites later on.
-> Note: This is only required if you are using a local database as authentication type.
-### Starting Web Setup <a id="starting-web-setup-from-package"></a>
+### Installing Icinga Web 2 <a id="installing-from-source-example"></a>
-Finally visit Icinga Web 2 in your browser to access the setup wizard and complete the installation:
-`/icingaweb2/setup`.
+Choose a target directory and move Icinga Web 2 there.
-> **Note for Debian/Ubuntu**
->
-> Use the same database, user and password details created above when asked.
+```bash
+mv icingaweb2 /usr/share/icingaweb2
+```
-The setup wizard automatically detects the required packages. In case one of them is missing,
-e.g. a PHP module, please install the package, restart your webserver and reload the setup page.
+### Configuring the Web Server <a id="configuring-web-server"></a>
-If you have SELinux enabled, please ensure to either have the selinux package for Icinga Web 2
-installed, or disable it.
+Use `icingacli` to generate web server configuration for either Apache or nginx.
+**Apache**:
+```bash
+./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public
+```
-### Upgrading to FPM <a id="upgrading-to-fpm"></a>
+**nginx**:
+```bash
+./bin/icingacli setup config webserver nginx --document-root /usr/share/icingaweb2/public
+```
-Valid for:
+Save the output as new file in your webserver's configuration directory.
-* RedHat / CentOS 7
+Example for Apache on RHEL or CentOS:
+```bash
+./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/httpd/conf.d/icingaweb2.conf
+```
-Other distributions are also possible if preferred, but not included here.
+Example for Apache on SUSE:
+```bash
+./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/apache2/conf.d/icingaweb2.conf
+```
-Some upgrading work needs to be done manually, while we install PHP FPM
-as dependency, you need to start the service, and configure some things.
+Example for Apache on Debian Jessie:
+```bash
+./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/apache2/conf-available/icingaweb2.conf
+a2enconf icingaweb2
+```
-Please read [Setting up FPM](02-Installation.md#setting-up-fpm) first.
+Example for Apache on Alpine Linux:
+```bash
+icingacli setup config webserver apache --document-root /usr/share/webapps/icingaweb2/public > /etc/apache2/conf.d/icingaweb2.conf
+```
+### Preparing Icinga Web 2 Setup <a id="preparing-web-setup-from-source"></a>
-**php.ini settings** you have tuned in the past needs to be migrated to a SCL installation
-of PHP.
+You can set up Icinga Web 2 quickly and easily with the Icinga Web 2 setup wizard which is available the first time
+you visit Icinga Web 2 in your browser. Please follow the steps listed below for preparing the web setup.
-Check these directories:
+Because both web and CLI must have access to configuration and logs, permissions will be managed using a special
+system group. The web server user and CLI user have to be added to this system group.
-* `/etc/php.ini`
-* `/etc/php.d/*.ini`
+Add the system group `icingaweb2` in the first place.
-PHP settings should be stored to:
+**Fedora, RHEL, CentOS, SLES and OpenSUSE**:
+```bash
+groupadd -r icingaweb2
+```
-* RedHat / CentOS 7: `/etc/opt/rh/rh-php71/php.d/`
+**Debian and Ubuntu**:
+```bash
+addgroup --system icingaweb2
+```
-Make sure to **install the required database modules**
+Add your web server's user to the system group `icingaweb2`
+and restart the web server:
-RedHat / CentOS 7:
-```
-yum install rh-php71-php-mysqlnd
-# or
-yum install rh-php71-php-pgsql
+**Fedora, RHEL and CentOS**:
+```bash
+usermod -a -G icingaweb2 apache
+service httpd restart
```
-After any PHP related change you now need to **restart FPM**:
+**SLES and OpenSUSE**:
+```bash
+usermod -A icingaweb2 wwwrun
+service apache2 restart
+```
-RedHat / CentOS 7:
+**Debian and Ubuntu**:
+```bash
+usermod -a -G icingaweb2 www-data
+service apache2 restart
```
-systemctl restart rh-php71-php-fpm.service
+
+**Alpine Linux**:
+```bash
+gpasswd -a apache icingaweb2
+rc-service apache2 restart
```
-If you don't need mod_php for other apps on the server, you should disable it in Apache.
-Disable PHP in Apache httpd:
+Use `icingacli` to create the configuration directory which defaults to **/etc/icingaweb2**:
+```bash
+./bin/icingacli setup config directory
```
-cd /etc/httpd
-cp conf.d/php.conf{,.bak}
-: >conf.d/php.conf
-# ONLY on el7!
-cp conf.modules.d/10-php.conf{,.bak}
-: >conf.modules.d/10-php.conf
-systemctl restart httpd.service
+When using the web setup you are required to authenticate using a token. In order to generate a token use the
+`icingacli`:
+```bash
+./bin/icingacli setup token create
```
-You can also uninstall the mod_php package, or all non-SCL PHP related packages.
-```
-yum remove php
-# or
-yum remove php-common
+In case you do not remember the token you can show it using the `icingacli`:
+```bash
+./bin/icingacli setup token show
```
+### Icinga Web 2 Setup Wizard <a id="web-setup-from-source-wizard"></a>
+
+Finally visit Icinga Web 2 in your browser to access the setup wizard and complete the installation:
+`/icingaweb2/setup`.
+
+Paste the previously generated token and follow the steps on-screen. Then you are done here.
+
+If you prefer to set up the configuration manually, follow the
+[Icinga Web 2 Manual Configuration instructions](20-Advanced-Topics.md#web-setup-manual-from-source-config)
+<!-- {% endif %} --><!-- {# end index if #} -->
=====================================
doc/02-Installation.md.d/01-Debian.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 on Debian
+<!-- {% set debian = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/02-Ubuntu.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 on Ubuntu
+<!-- {% set ubuntu = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/03-CentOS.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 on CentOS
+<!-- {% set centos = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/04-RHEL.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 on RHEL
+<!-- {% set rhel = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/05-SLES.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga 2 on SLES
+<!-- {% set sles = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/06-Amazon-Linux.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 on Amazon Linux
+<!-- {% set amazon_linux = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/02-Installation.md.d/07-From-Source.md
=====================================
@@ -0,0 +1,3 @@
+# Install Icinga Web 2 from Source
+<!-- {% set from_source = True %} -->
+<!-- {% include "02-Installation.md" %} -->
=====================================
doc/20-Advanced-Topics.md
=====================================
@@ -151,168 +151,7 @@ Example from [puppet-icingaweb2](https://github.com/Icinga/puppet-icingaweb2):
```
-
-
-## Installing Icinga Web 2 from Source <a id="installing-from-source"></a>
-
-Although the preferred way of installing Icinga Web 2 is to use packages, it is also possible to install Icinga Web 2
-directly from source.
-
-### Getting the Source <a id="getting-the-source"></a>
-
-First of all, you need to download the sources.
-
-Git clone:
-
-```
-cd /usr/share/
-git clone https://github.com/Icinga/icingaweb2.git icingaweb2
-```
-
-Tarball download (latest [release](https://github.com/Icinga/icingaweb2/releases/latest)):
-
-```
-cd /usr/share
-wget https://github.com/Icinga/icingaweb2/archive/v2.4.1.zip
-unzip v2.4.1.zip
-mv icingaweb2-2.4.1 icingaweb2
-```
-
-### Installing Requirements from Source <a id="installing-from-source-requirements"></a>
-
-You will need to install certain dependencies depending on your setup listed [here](02-Installation.md#installing-requirements).
-
-The following example installs Apache2 as web server, MySQL as RDBMS and uses the PHP adapter for MySQL.
-Adopt the package requirements to your needs (e.g. adding ldap for authentication) and distribution.
-
-Example for RHEL/CentOS/Fedora:
-
-```
-yum install httpd mysql-server
-yum install php php-gd php-intl php-ZendFramework php-ZendFramework-Db-Adapter-Pdo-Mysql
-```
-
-The setup wizard will check the pre-requisites later on.
-
-
-### Installing Icinga Web 2 <a id="installing-from-source-example"></a>
-
-Choose a target directory and move Icinga Web 2 there.
-
-```
-mv icingaweb2 /usr/share/icingaweb2
-```
-
-### Configuring the Web Server <a id="configuring-web-server"></a>
-
-Use `icingacli` to generate web server configuration for either Apache or nginx.
-
-**Apache**:
-```
-./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public
-```
-
-**nginx**:
-```
-./bin/icingacli setup config webserver nginx --document-root /usr/share/icingaweb2/public
-```
-
-Save the output as new file in your webserver's configuration directory.
-
-Example for Apache on RHEL or CentOS:
-```
-./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/httpd/conf.d/icingaweb2.conf
-```
-
-Example for Apache on SUSE:
-```
-./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/apache2/conf.d/icingaweb2.conf
-```
-
-Example for Apache on Debian Jessie:
-```
-./bin/icingacli setup config webserver apache --document-root /usr/share/icingaweb2/public > /etc/apache2/conf-available/icingaweb2.conf
-a2enconf icingaweb2
-```
-
-Example for Apache on Alpine Linux:
-```
-icingacli setup config webserver apache --document-root /usr/share/webapps/icingaweb2/public > /etc/apache2/conf.d/icingaweb2.conf
-```
-### Preparing Icinga Web 2 Setup <a id="preparing-web-setup-from-source"></a>
-
-You can set up Icinga Web 2 quickly and easily with the Icinga Web 2 setup wizard which is available the first time
-you visit Icinga Web 2 in your browser. Please follow the steps listed below for preparing the web setup.
-
-Because both web and CLI must have access to configuration and logs, permissions will be managed using a special
-system group. The web server user and CLI user have to be added to this system group.
-
-Add the system group `icingaweb2` in the first place.
-
-**Fedora, RHEL, CentOS, SLES and OpenSUSE**:
-```
-groupadd -r icingaweb2
-```
-
-**Debian and Ubuntu**:
-```
-addgroup --system icingaweb2
-```
-
-Add your web server's user to the system group `icingaweb2`
-and restart the web server:
-
-**Fedora, RHEL and CentOS**:
-```
-usermod -a -G icingaweb2 apache
-service httpd restart
-```
-
-**SLES and OpenSUSE**:
-```
-usermod -A icingaweb2 wwwrun
-service apache2 restart
-```
-
-**Debian and Ubuntu**:
-```
-usermod -a -G icingaweb2 www-data
-service apache2 restart
-```
-
-**Alpine Linux**:
-```
-gpasswd -a apache icingaweb2
-rc-service apache2 restart
-```
-
-
-Use `icingacli` to create the configuration directory which defaults to **/etc/icingaweb2**:
-```
-./bin/icingacli setup config directory
-```
-
-
-When using the web setup you are required to authenticate using a token. In order to generate a token use the
-`icingacli`:
-```
-./bin/icingacli setup token create
-```
-
-In case you do not remember the token you can show it using the `icingacli`:
-```
-./bin/icingacli setup token show
-```
-
-### Icinga Web 2 Setup Wizard <a id="web-setup-from-source-wizard"></a>
-
-Finally visit Icinga Web 2 in your browser to access the setup wizard and complete the installation:
-`/icingaweb2/setup`.
-
-Paste the previously generated token and follow the steps on-screen. Then you are done here.
-
-
-### Icinga Web 2 Manual Setup <a id="web-setup-manual-from-source"></a>
+## Icinga Web 2 Manual Setup <a id="web-setup-manual-from-source"></a>
If you have chosen not to run the setup wizard, you will need further knowledge
about
@@ -329,10 +168,11 @@ Puppet, Ansible, Chef, etc.
> Read the documentation on the respective linked configuration sections before
> deploying the configuration manually.
>
-> If you are unsure about certain settings, use the [setup wizard](02-Installation.md#web-setup-wizard-from-source) once
-> and then collect the generated configuration as well as sql dumps.
+> If you are unsure about certain settings, use the setup wizard as described in the
+> [installation instructions](02-Installation.md) once and then collect the generated
+> configuration as well as sql dumps.
-#### Icinga Web 2 Manual Database Setup <a id="web-setup-manual-from-source-database"></a>
+### Icinga Web 2 Manual Database Setup <a id="web-setup-manual-from-source-database"></a>
Create the database and add a new user as shown below for MySQL/MariaDB:
@@ -357,7 +197,7 @@ INSERT INTO icingaweb_user (name, active, password_hash) VALUES ('icingaadmin',
quit
```
-#### Icinga Web 2 Manual Configuration <a id="web-setup-manual-from-source-config"></a>
+### Icinga Web 2 Manual Configuration <a id="web-setup-manual-from-source-config"></a>
[resources.ini](04-Resources.md#resources) providing the details for the Icinga Web 2 and
@@ -423,7 +263,7 @@ users = "icingaadmin"
permissions = "*"
```
-#### Icinga Web 2 Manual Configuration Monitoring Module <a id="web-setup-manual-from-source-config-monitoring-module"></a>
+### Icinga Web 2 Manual Configuration Monitoring Module <a id="web-setup-manual-from-source-config-monitoring-module"></a>
**config.ini** defining additional security settings.
@@ -458,11 +298,10 @@ username = "api"
password = "api"
```
-#### Icinga Web 2 Manual Setup Login <a id="web-setup-manual-from-source-login"></a>
+### Icinga Web 2 Manual Setup Login <a id="web-setup-manual-from-source-login"></a>
Finally visit Icinga Web 2 in your browser to login as `icingaadmin` user: `/icingaweb2`.
-
## Automating the Installation of Icinga Web 2 <a id="web-setup-automation"></a>
Prior to creating your own script, please look into the official resources
@@ -483,7 +322,7 @@ by Icinga Web 2.
4. Insert administrator user in the `icingaweb2` database:
`INSERT INTO icingaweb_user (name, active, password_hash) VALUES ('admin', 1, '<hash>')`, where `<hash>` is the output
of `php -r 'echo password_hash("yourtopsecretpassword", PASSWORD_DEFAULT);'`.
-5. Make sure the `ido-mysql` and `api` features are enabled in Icinga 2: `icinga2 feature enable ido-mysql` and
+5. Make sure the `ido-mysql` and `api` features are enabled in Icinga 2: `icinga2 feature enable ido-mysql` and
`icinga2 feature enable api`.
6. Generate Apache/nginx config. This command will print an apache config for you on stdout:
`icingacli setup config webserver apache`. Similarly for nginx. You need to place that configuration in the right place,
=====================================
library/Icinga/Application/Version.php
=====================================
@@ -8,7 +8,7 @@ namespace Icinga\Application;
*/
class Version
{
- const VERSION = '2.9.5';
+ const VERSION = '2.9.6';
/**
* Get the version of this instance of Icinga Web 2
=====================================
library/Icinga/Web/Controller/StaticController.php
=====================================
@@ -39,10 +39,21 @@ class StaticController
}
$assetRoot = $library->getStaticAssetPath();
+ if (empty($assetRoot)) {
+ $app->getResponse()
+ ->setHttpResponseCode(404);
+
+ return;
+ }
+
$filePath = $assetRoot . DIRECTORY_SEPARATOR . $assetPath;
+ $dirPath = realpath(dirname($filePath)); // dirname, because the file may be a link
- // Doesn't use realpath as it isn't supposed to access files outside asset/static
- if (! is_readable($filePath) || ! is_file($filePath)) {
+ if (
+ $dirPath === false
+ || substr($dirPath, 0, strlen($assetRoot)) !== $assetRoot
+ || ! is_file($filePath)
+ ) {
$app->getResponse()
->setHttpResponseCode(404);
=====================================
modules/doc/module.info
=====================================
@@ -1,4 +1,4 @@
Module: doc
-Version: 2.9.5
+Version: 2.9.6
Description: Documentation module
Extracts, shows and exports documentation for Icinga Web 2 and its modules.
=====================================
modules/migrate/module.info
=====================================
@@ -1,5 +1,5 @@
Module: migrate
-Version: 2.9.5
+Version: 2.9.6
Description: Migrate module
This module was introduced with the domain-aware authentication feature in version 2.5.0.
It helps you migrating users and user configurations according to a given domain.
=====================================
modules/monitoring/library/Monitoring/Backend/Ido/Query/HostcontactQuery.php
=====================================
@@ -89,7 +89,7 @@ class HostcontactQuery extends IdoQuery
[]
)->join(
['co' => $this->prefix . 'objects'],
- 'co.object_id = c.contact_object_id AND co.is_active = 1',
+ 'co.object_id = c.contact_object_id AND co.is_active = 1 AND co.objecttype_id = 10',
[]
);
@@ -153,7 +153,7 @@ class HostcontactQuery extends IdoQuery
[]
)->joinLeft(
['ho' => $this->prefix . 'objects'],
- 'ho.object_id = h.host_object_id AND ho.is_active = 1',
+ 'ho.object_id = h.host_object_id AND ho.is_active = 1 AND ho.objecttype_id = 1',
[]
);
}
=====================================
modules/monitoring/library/Monitoring/Backend/Ido/Query/HostserviceproblemsummaryQuery.php
=====================================
@@ -72,7 +72,7 @@ class HostserviceproblemsummaryQuery extends IdoQuery
array()
)->join(
array('s' => $this->prefix . 'services'),
- 's.service_object_id = so.object_id AND so.is_active = 1',
+ 's.service_object_id = so.object_id AND so.is_active = 1 AND so.objecttype_id = 2',
array()
);
$this->select->group('so.name1');
=====================================
modules/monitoring/library/Monitoring/Backend/Ido/Query/IdoQuery.php
=====================================
@@ -1191,14 +1191,32 @@ abstract class IdoQuery extends DbQuery
$this->customVars[strtolower($customvar)] = $alias;
- if ($this->hasJoinedVirtualTable('services')) {
- $leftcol = 's.' . $type . '_object_id';
- } elseif ($type === 'service') {
- $this->requireVirtualTable('services');
- $leftcol = 's.service_object_id';
- } else {
- $this->requireVirtualTable('hosts');
- $leftcol = 'h.host_object_id';
+ if ($type === 'host') {
+ if (
+ $this instanceof HostserviceproblemsummaryQuery
+ || $this instanceof ServicecommentQuery
+ || $this instanceof ServicedowntimeQuery
+ || $this instanceof ServicecommenthistoryQuery
+ || $this instanceof ServicedowntimestarthistoryQuery
+ || $this instanceof ServiceflappingstarthistoryQuery
+ || $this instanceof ServicegroupQuery
+ || $this instanceof ServicenotificationQuery
+ || $this instanceof ServicestatehistoryQuery
+ || $this instanceof ServicestatusQuery
+ ) {
+ $this->requireVirtualTable('services');
+ $leftcol = 's.host_object_id';
+ } else {
+ $leftcol = 'ho.object_id';
+ if (! $this->hasJoinedTable('ho')) {
+ $this->requireVirtualTable('hosts');
+ }
+ }
+ } else { // $type === 'service'
+ $leftcol = 'so.object_id';
+ if (! $this->hasJoinedTable('so')) {
+ $this->requireVirtualTable('services');
+ }
}
$mapped = $this->getMappedField($leftcol);
=====================================
modules/monitoring/library/Monitoring/Backend/Ido/Query/ServicecontactQuery.php
=====================================
@@ -89,7 +89,7 @@ class ServicecontactQuery extends IdoQuery
[]
)->join(
['co' => $this->prefix . 'objects'],
- 'co.object_id = c.contact_object_id AND co.is_active = 1',
+ 'co.object_id = c.contact_object_id AND co.is_active = 1 AND co.objecttype_id = 10',
[]
);
@@ -163,7 +163,7 @@ class ServicecontactQuery extends IdoQuery
[]
)->joinLeft(
['ho' => $this->prefix . 'objects'],
- 'ho.object_id = h.host_object_id AND ho.is_active = 1',
+ 'ho.object_id = h.host_object_id AND ho.is_active = 1 AND ho.objecttype_id = 1',
[]
);
}
=====================================
modules/monitoring/module.info
=====================================
@@ -1,5 +1,5 @@
Module: monitoring
-Version: 2.9.5
+Version: 2.9.6
Description: Icinga monitoring module
IDO accessor and UI for your monitoring. This is the initial instalment for a
graphical presentation of Icinga environments. The predecessor of Icinga DB.
=====================================
modules/setup/module.info
=====================================
@@ -1,5 +1,5 @@
Module: setup
-Version: 2.9.5
+Version: 2.9.6
Description: Setup module
Web based wizard for setting up Icinga Web 2 and its modules.
This includes the data backends (e.g. relational database, LDAP),
=====================================
modules/test/module.info
=====================================
@@ -1,5 +1,5 @@
Module: test
-Version: 2.9.5
+Version: 2.9.6
Description: Translation module
This module allows developers to run (unit) tests against Icinga Web 2 and
any of its modules. Usually you do not need to enable this.
=====================================
modules/translation/module.info
=====================================
@@ -1,5 +1,5 @@
Module: translation
-Version: 2.9.5
+Version: 2.9.6
Description: Translation module
This module allows developers and translators to translate modules for multiple
languages. You do not need this module to run an internationalized web frontend.
View it on GitLab: https://salsa.debian.org/nagios-team/pkg-icingaweb2/-/compare/394e48c99ecbd07fd9cdf852be2eddc0b8a3839a...59e903d5b102bf69a2c75a498ccde82f702972fb
--
View it on GitLab: https://salsa.debian.org/nagios-team/pkg-icingaweb2/-/compare/394e48c99ecbd07fd9cdf852be2eddc0b8a3839a...59e903d5b102bf69a2c75a498ccde82f702972fb
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-nagios-changes/attachments/20220308/d133a0fb/attachment-0001.htm>
More information about the pkg-nagios-changes
mailing list