Hello community,

here is the log from the commit of package icinga2 for openSUSE:Factory checked 
in at 2018-05-02 12:20:06
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/icinga2 (Old)
 and      /work/SRC/openSUSE:Factory/.icinga2.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "icinga2"

Wed May  2 12:20:06 2018 rev:7 rq:603002 version:2.8.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/icinga2/icinga2.changes  2018-04-19 
15:30:39.168191771 +0200
+++ /work/SRC/openSUSE:Factory/.icinga2.new/icinga2.changes     2018-05-02 
12:20:12.560268339 +0200
@@ -1,0 +2,12 @@
+Fri Apr 27 12:47:12 UTC 2018 - [email protected]
+
+- update to version 2.8.4
+  * fix plugins crash when run from icinga2-2.8.3
+  * Fix InfluxDB backslash escaping
+  * Fix Elasticsearch crash on invalid performance data
+  * Sysconfig file settings are taken into account
+  * Support multiple parameters for check_nscp_api
+  * Documentation enhancements and fixes
+- remove obsolete patch icinga2-2.8.2-boost.patch
+
+-------------------------------------------------------------------

Old:
----
  icinga2-2.8.2-boost.patch
  v2.8.2.tar.gz

New:
----
  v2.8.4.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ icinga2.spec ++++++
--- /var/tmp/diff_new_pack.sqSWRp/_old  2018-05-02 12:20:13.612229958 +0200
+++ /var/tmp/diff_new_pack.sqSWRp/_new  2018-05-02 12:20:13.616229812 +0200
@@ -83,14 +83,12 @@
 License:        GPL-2.0-or-later
 Group:          System/Monitoring
 Name:           icinga2
-Version:        2.8.2
+Version:        2.8.4
 Release:        %{revision}%{?dist}
 Url:            https://www.icinga.com/
 Source:         https://github.com/Icinga/%{name}/archive/v%{version}.tar.gz
 
 Source1:        icinga2-rpmlintrc
-# PATCH-FIX-UPSTREAM bsc#1089808
-Patch0:         icinga2-2.8.2-boost.patch
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 Requires:       %{name}-bin = %{version}-%{release}
@@ -297,7 +295,6 @@
 %if "%{_vendor}" == "suse"
 find . -type f -name '*.sh' -exec sed -i -e 's|\/usr\/bin\/env 
bash|\/bin\/bash|g' {} \;
 %endif
-%patch0 -p1
 
 %build
 CMAKE_OPTS="-DCMAKE_INSTALL_PREFIX=/usr \

++++++ v2.8.2.tar.gz -> v2.8.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/AUTHORS new/icinga2-2.8.4/AUTHORS
--- old/icinga2-2.8.2/AUTHORS   2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/AUTHORS   2018-04-25 15:11:31.000000000 +0200
@@ -71,6 +71,7 @@
 Irina Kaprizkina <[email protected]>
 James Pharaoh <[email protected]>
 Jan Andres <[email protected]>
+Jan Beich <[email protected]>
 Jan Wagner <[email protected]>
 Jason Young <[email protected]>
 Jean Flach <[email protected]>
@@ -92,6 +93,7 @@
 Lars Krüger <[email protected]>
 Lee Clemens <[email protected]>
 Lennart Betz <[email protected]>
+lihan <[email protected]>
 Louis Sautier <[email protected]>
 Luca Lesinigo <[email protected]>
 Lucas Fairchild-Madar <[email protected]>
@@ -109,6 +111,7 @@
 Mathieu Lutfy <[email protected]>
 Matthaus Owens <[email protected]>
 Matthias Schales <[email protected]>
+Maurice Meyer <[email protected]>
 Max Rosin <[email protected]>
 Max Zhang <[email protected]>
 Mhd Sulhan <[email protected]>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/CHANGELOG.md 
new/icinga2-2.8.4/CHANGELOG.md
--- old/icinga2-2.8.2/CHANGELOG.md      2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/CHANGELOG.md      2018-04-25 15:11:31.000000000 +0200
@@ -1,5 +1,66 @@
 # Icinga 2.x CHANGELOG
 
+## 2.8.4 (2018-04-25)
+
+### Bug
+
+* [#6257](https://github.com/icinga/icinga2/issues/6257) (Check Execution): 
Plugins crash when run from icinga2-2.8.3 
+
+### Support
+
+* [#6260](https://github.com/icinga/icinga2/issues/6260) (Check Execution, 
PR): Revert "fixup set rlimit stack failed condition"
+
+## 2.8.3 (2018-04-24)
+
+### Notes
+
+- Fix InfluxDB backslash escaping
+- Fix Elasticsearch crash on invalid performance data
+- Sysconfig file settings are taken into account
+- Support multiple parameters for check_nscp_api
+- Documentation enhancements and fixes
+
+### Bug
+
+* [#6207](https://github.com/icinga/icinga2/issues/6207) (Plugins, Windows, 
PR): Fix multiple parameter problems for check\_nscp\_api
+* [#6196](https://github.com/icinga/icinga2/issues/6196) (InfluxDB, Metrics, 
PR): Fix InfluxDB backslash escaping
+* [#6192](https://github.com/icinga/icinga2/issues/6192) (Crash, 
Elasticsearch, PR): Elasticsearch: Fix crash with invalid performance data 
metrics
+* [#6191](https://github.com/icinga/icinga2/issues/6191) (Crash, 
Elasticsearch): Invalid Perfdata causing Segmentation fault with 
ElasticsearchWriter
+* [#6182](https://github.com/icinga/icinga2/issues/6182) (InfluxDB): Windows 
Disk performance data broken in InfluxDB
+* [#6179](https://github.com/icinga/icinga2/issues/6179) (CLI, Crash, PR): Fix 
crash in api user command
+* [#6178](https://github.com/icinga/icinga2/issues/6178) (API, Crash): Error: 
boost::bad\_any\_cast: failed conversion using boost::any\_cast
+* [#6140](https://github.com/icinga/icinga2/issues/6140): Force check has no 
effect
+* [#6119](https://github.com/icinga/icinga2/issues/6119) (PR): fixup set 
rlimit stack failed condition
+* [#5925](https://github.com/icinga/icinga2/issues/5925) (Crash, PR): Fix 
missing variable name in ApiListener::Start
+* [#5924](https://github.com/icinga/icinga2/issues/5924) (Crash): The lock 
variable in ApiListener::Start is missing its name
+* [#5881](https://github.com/icinga/icinga2/issues/5881) (API, PR): Fix 
package error message
+* [#5706](https://github.com/icinga/icinga2/issues/5706) (Plugins, Windows): 
nscp\_api - cannot use check\_cpu with "time" argument used multiple times
+
+### Documentation
+
+* [#6227](https://github.com/icinga/icinga2/issues/6227) (Documentation, PR): 
Fix missing anchors in CLI commands chapter
+* [#6203](https://github.com/icinga/icinga2/issues/6203) (Documentation, PR): 
Add docs for script debugger and API filters
+* [#6177](https://github.com/icinga/icinga2/issues/6177) (Documentation, PR): 
Doc: Fix typo in API user creation example
+* [#6176](https://github.com/icinga/icinga2/issues/6176) (Documentation, PR): 
hashed\_password -\> password\_hash. Fixes \#6175
+* [#6175](https://github.com/icinga/icinga2/issues/6175) (Documentation): 
ApiUser does not know hashed\_password Attribute
+* [#6166](https://github.com/icinga/icinga2/issues/6166) (Documentation, PR): 
Fix broken link in README
+* [#6145](https://github.com/icinga/icinga2/issues/6145) (Documentation, PR): 
Fix incorrect parameter name in the API documentation
+* [#6102](https://github.com/icinga/icinga2/issues/6102) (Documentation, PR): 
Fix typo in Apply for Rules documentation
+* [#6080](https://github.com/icinga/icinga2/issues/6080) (Documentation, PR): 
Document the 'ignore\_on\_error' attribute for object creation
+* [#6068](https://github.com/icinga/icinga2/issues/6068) (Documentation, PR): 
Fix the explanation of `types` and `states` for user objects
+* [#5913](https://github.com/icinga/icinga2/issues/5913) (Documentation, ITL, 
PR): Enhance http\_certificate parameter documentation
+* [#5838](https://github.com/icinga/icinga2/issues/5838) (Documentation, PR): 
services.conf has also be moved to zones.d/global-templates/
+* [#5797](https://github.com/icinga/icinga2/issues/5797) (Documentation): 
Document the ignore\_on\_error parameter for CreateObjectHandler::HandleRequest
+* [#5610](https://github.com/icinga/icinga2/issues/5610) (Documentation, ITL): 
http check doesn't map the critical ssl certificate age option
+
+### Support
+
+* [#6250](https://github.com/icinga/icinga2/issues/6250) (PR): Fix typo
+* [#6241](https://github.com/icinga/icinga2/issues/6241) (Packages, PR): Fix 
Sysconfig file detection for Icinga 2 settings
+* [#6230](https://github.com/icinga/icinga2/issues/6230) (PR): Unbreak build 
against Boost 1.67
+* [#6215](https://github.com/icinga/icinga2/issues/6215) (Configuration, 
Packages): Sysconfig limits and settings are not respected
+* [#6202](https://github.com/icinga/icinga2/issues/6202) (Packages, 
code-quality, PR): Use VERSION instead of icinga2.spec
+
 ## 2.8.2 (2018-03-22)
 
 ### Notes
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/CMakeLists.txt 
new/icinga2-2.8.4/CMakeLists.txt
--- old/icinga2-2.8.2/CMakeLists.txt    2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/CMakeLists.txt    2018-04-25 15:11:31.000000000 +0200
@@ -40,7 +40,7 @@
 option(ICINGA2_WITH_STUDIO "Build the Icinga Studio application" OFF)
 option(ICINGA2_WITH_TESTS "Run unit tests" ON)
 
-file(STRINGS icinga2.spec VERSION_LINE REGEX "^Version: ")
+file(STRINGS VERSION VERSION_LINE REGEX "^Version: ")
 string(REPLACE "Version: " "" ICINGA2_VERSION ${VERSION_LINE})
 
 include(GNUInstallDirs)
@@ -55,6 +55,11 @@
 set(ICINGA2_UNITY_BUILD ON CACHE BOOL "Whether to perform a unity build")
 set(ICINGA2_LTO_BUILD OFF CACHE BOOL "Whether to use LTO")
 
+if(NOT WIN32)
+  set(ICINGA2_SYSCONFIGFILE 
"${CMAKE_INSTALL_FULL_SYSCONFDIR}/sysconfig/icinga2" CACHE PATH "where to store 
configuation for the init system, defaults to /etc/sysconfig/icinga2")
+
+endif()
+
 site_name(ICINGA2_BUILD_HOST_NAME)
 set(ICINGA2_BUILD_COMPILER_NAME "${CMAKE_CXX_COMPILER_ID}")
 
@@ -70,7 +75,7 @@
 set(ICINGA2_LICENSE 
"${ICINGA2_LICENSE_GPL}\n\n---\n\n${ICINGA2_LICENSE_ADDITIONS}")
 file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/LICENSE.txt" ${ICINGA2_LICENSE})
 
-file(STRINGS icinga2.spec SPEC_VERSION REGEX "^Version:")
+file(STRINGS VERSION SPEC_VERSION REGEX "^Version:")
 string(LENGTH "${SPEC_VERSION}" SPEC_VERSION_LENGTH)
 math(EXPR SPEC_VERSION_LENGTH "${SPEC_VERSION_LENGTH} - 9")
 string(SUBSTRING ${SPEC_VERSION} 9 ${SPEC_VERSION_LENGTH} SPEC_VERSION)
@@ -83,10 +88,10 @@
   configure_file(icinga-version.h.force 
${CMAKE_CURRENT_BINARY_DIR}/icinga-version.h COPYONLY)
 else()
   if(NOT ICINGA2_GIT_VERSION_INFO OR GIT_VERSION MATCHES "-NOTFOUND$")
-    file(STRINGS icinga2.spec SPEC_REVISION REGEX "^%define revision ")
+    file(STRINGS VERSION SPEC_REVISION REGEX "^Revision: ")
     string(LENGTH "${SPEC_REVISION}" SPEC_REVISION_LENGTH)
-    math(EXPR SPEC_REVISION_LENGTH "${SPEC_REVISION_LENGTH} - 17")
-    string(SUBSTRING ${SPEC_REVISION} 17 ${SPEC_REVISION_LENGTH} SPEC_REVISION)
+    math(EXPR SPEC_REVISION_LENGTH "${SPEC_REVISION_LENGTH} - 10")
+    string(SUBSTRING ${SPEC_REVISION} 10 ${SPEC_REVISION_LENGTH} SPEC_REVISION)
 
     set(GIT_VERSION "r${SPEC_VERSION}-${SPEC_REVISION}")
   endif()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/INSTALL.md new/icinga2-2.8.4/INSTALL.md
--- old/icinga2-2.8.2/INSTALL.md        2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/INSTALL.md        2018-04-25 15:11:31.000000000 +0200
@@ -128,7 +128,7 @@
 
 CMake determines the Icinga 2 version number using `git describe` if the
 source directory is contained in a Git repository. Otherwise the version number
-is extracted from the [icinga2.spec](icinga2.spec) file. This behavior can be
+is extracted from the [VERSION](VERSION) file. This behavior can be
 overridden by creating a file called `icinga-version.h.force` in the source
 directory. Alternatively the `-DICINGA2_GIT_VERSION_INFO=OFF` option for CMake
 can be used to disable the usage of `git describe`.
@@ -164,7 +164,9 @@
 
 Copy the icinga2.spec file to `rpmbuild/SPEC` or fetch the latest version:
 
-    curl https://raw.githubusercontent.com/Icinga/icinga2/master/icinga2.spec 
-o $HOME/rpmbuild/SPECS/icinga2.spec
+```
+curl https://raw.githubusercontent.com/Icinga/rpm-icinga2/master/icinga2.spec 
-o $HOME/rpmbuild/SPECS/icinga2.spec
+```
 
 Copy the tarball to `rpmbuild/SOURCES` e.g. by using the `spectool` binary
 provided with `rpmdevtools`:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/README.md new/icinga2-2.8.4/README.md
--- old/icinga2-2.8.2/README.md 2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/README.md 2018-04-25 15:11:31.000000000 +0200
@@ -25,7 +25,7 @@
 as web interface.
 
 More information can be found at 
[www.icinga.com](https://www.icinga.com/products/icinga-2/)
-and inside the [documentation](doc/1-about.md).
+and inside the [documentation](https://www.icinga.com/docs/icinga2/latest/).
 
 ## License
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/RELEASE.md new/icinga2-2.8.4/RELEASE.md
--- old/icinga2-2.8.2/RELEASE.md        2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/RELEASE.md        2018-04-25 15:11:31.000000000 +0200
@@ -29,7 +29,7 @@
 Update the version in the spec file:
 
 ```
-gsed -i "s/Version: .*/Version: $VERSION/g" icinga2.spec
+gsed -i "s/Version: .*/Version: $VERSION/g" VERSION
 ```
 
 ## Changelog
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/VERSION new/icinga2-2.8.4/VERSION
--- old/icinga2-2.8.2/VERSION   1970-01-01 01:00:00.000000000 +0100
+++ new/icinga2-2.8.4/VERSION   2018-04-25 15:11:31.000000000 +0200
@@ -0,0 +1,2 @@
+Version: 2.8.4
+Revision: 1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/03-monitoring-basics.md 
new/icinga2-2.8.4/doc/03-monitoring-basics.md
--- old/icinga2-2.8.2/doc/03-monitoring-basics.md       2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/doc/03-monitoring-basics.md       2018-04-25 
15:11:31.000000000 +0200
@@ -1082,7 +1082,7 @@
      iftraffic_units = "g"
      //iftraffic_community = IftrafficSnmpCommunity
      iftraffic_bandwidth = 1
-     vlan = "renote"
+     vlan = "remote"
      qos = "enabled"
   }
   vars.interfaces["MgmtInterface1"] = {
@@ -1245,7 +1245,7 @@
     * iftraffic_units = "g"
       % = modified in '/etc/icinga2/conf.d/iftraffic.conf', lines 52:3-52:57
     * qos = "enabled"
-    * vlan = "renote"
+    * vlan = "remote"
 
 Object 'cisco-catalyst-6509-34!if-MgmtInterface1' of type 'Service':
 ...
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/06-distributed-monitoring.md 
new/icinga2-2.8.4/doc/06-distributed-monitoring.md
--- old/icinga2-2.8.2/doc/06-distributed-monitoring.md  2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/doc/06-distributed-monitoring.md  2018-04-25 
15:11:31.000000000 +0200
@@ -1850,7 +1850,7 @@
 Example:
 
     [[email protected] /]# cd /etc/icinga2/conf.d
-    [[email protected] /etc/icinga2/conf.d]# cp 
{commands,downtimes,groups,notifications,templates,timeperiods,users}.conf 
/etc/icinga2/zones.d/global-templates
+    [[email protected] /etc/icinga2/conf.d]# cp 
{commands,downtimes,groups,notifications,services,templates,timeperiods,users}.conf
 /etc/icinga2/zones.d/global-templates
 
 ### Health Checks <a id="distributed-monitoring-health-checks"></a>
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/09-object-types.md 
new/icinga2-2.8.4/doc/09-object-types.md
--- old/icinga2-2.8.2/doc/09-object-types.md    2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/doc/09-object-types.md    2018-04-25 15:11:31.000000000 
+0200
@@ -108,7 +108,7 @@
   Name                      | Type                  | Description
   
--------------------------|-----------------------|----------------------------------
   password                  | String                | **Optional.** Password 
string. Note: This attribute is hidden in API responses.
-  hashed\_password          | String                | **Optional.** A hashed 
password string in the form of /etc/shadow. Note: This attribute is hidden in 
API responses.
+  password\_hash            | String                | **Optional.** A hashed 
password string in the form of /etc/shadow. Note: This attribute is hidden in 
API responses.
   client\_cn                | String                | **Optional.** Client 
Common Name (CN).
   permissions               | Array                 | **Required.** Array of 
permissions. Either as string or dictionary with the keys `permission` and 
`filter`. The latter must be specified as function.
 
@@ -1739,8 +1739,8 @@
   groups                    | Array of object names | **Optional.** An array 
of group names.
   enable\_notifications     | Boolean               | **Optional.** Whether 
notifications are enabled for this user.
   period                    | Object name           | **Optional.** The name 
of a time period which determines when a notification for this user should be 
triggered. Not set by default.
-  types                     | Array                 | **Optional.** A set of 
type filters when this notification should be triggered. By default everything 
is matched.
-  states                    | Array                 | **Optional.** A set of 
state filters when this notification should be triggered. By default everything 
is matched.
+  types                     | Array                 | **Optional.** A set of 
type filters when a notification for this user should be triggered. By default 
everything is matched.
+  states                    | Array                 | **Optional.** A set of 
state filters when a notification for this should be triggered. By default 
everything is matched.
 
 Runtime Attributes:
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/10-icinga-template-library.md 
new/icinga2-2.8.4/doc/10-icinga-template-library.md
--- old/icinga2-2.8.2/doc/10-icinga-template-library.md 2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/doc/10-icinga-template-library.md 2018-04-25 
15:11:31.000000000 +0200
@@ -605,7 +605,7 @@
 http_warn_time                   | **Optional.** The warning threshold.
 http_critical_time               | **Optional.** The critical threshold.
 http_expect                      | **Optional.** Comma-delimited list of 
strings, at least one of them is expected in the first (status) line of the 
server response. Default: HTTP/1.
-http_certificate                 | **Optional.** Minimum number of days a 
certificate has to be valid. This parameter explicitly sets the port to 443 and 
ignores the URL if passed.
+http_certificate                 | **Optional.** Minimum number of days a 
certificate has to be valid. Port defaults to 443. When this option is used the 
URL is not checked. The first parameter defines the warning threshold (in 
days), the second parameter the critical threshold (in days). (Example 
`http_certificate = "30,20"`).
 http_clientcert                  | **Optional.** Name of file contains the 
client certificate (PEM format).
 http_privatekey                  | **Optional.** Name of file contains the 
private key (PEM format).
 http_headerstring                | **Optional.** String to expect in the 
response headers.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/11-cli-commands.md 
new/icinga2-2.8.4/doc/11-cli-commands.md
--- old/icinga2-2.8.2/doc/11-cli-commands.md    2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/doc/11-cli-commands.md    2018-04-25 15:11:31.000000000 
+0200
@@ -396,7 +396,7 @@
 Icinga home page: <https://www.icinga.com/>
 ```
 
-### Config Files
+### Config Files <a id="cli-command-daemon-config-files"></a>
 
 You can specify one or more configuration files with the `--config` option.
 Configuration files are processed in the order they're specified on the 
command-line.
@@ -405,7 +405,7 @@
 Icinga 2 automatically falls back to using the configuration file
 `SysconfDir + "/icinga2/icinga2.conf"` (where SysconfDir is usually `/etc`).
 
-### Config Validation
+### Validation <a id="cli-command-daemon-validation"></a>
 
 The `--validate` option can be used to check if configuration files
 contain errors. If any errors are found, the exit status is 1, otherwise 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/12-icinga2-api.md 
new/icinga2-2.8.4/doc/12-icinga2-api.md
--- old/icinga2-2.8.2/doc/12-icinga2-api.md     2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/doc/12-icinga2-api.md     2018-04-25 15:11:31.000000000 
+0200
@@ -27,7 +27,7 @@
 added to your configuration. Example:
 
 ```
-$ icinga2 api user --user icingaweb2 --passwd icinga
+$ icinga2 api user --user icingaweb2 --password icinga
 object ApiUser "icingaweb2" {
   password_hash 
="$5$d5f1a17ea308acb6$9e9fd5d24a9373a16e8811765cc5a5939687faf9ef8ed496db6e7f1d0ae9b2a9"
   // client_cn = ""
@@ -603,10 +603,11 @@
 New objects must be created by sending a PUT request. The following
 parameters need to be passed inside the JSON body:
 
-  Parameters | Type         | Description
-  -----------|--------------|--------------------------
-  templates  | Array        | **Optional.** Import existing configuration 
templates for this object type. Note: These templates must either be statically 
configured or provided in [config 
packages](12-icinga2-api.md#icinga2-api-config-management)-
-  attrs      | Dictionary   | **Required.** Set specific object attributes for 
this [object type](09-object-types.md#object-types).
+  Parameters        | Type         | Description
+  ------------------|--------------|--------------------------
+  templates         | Array        | **Optional.** Import existing 
configuration templates for this object type. Note: These templates must either 
be statically configured or provided in [config 
packages](12-icinga2-api.md#icinga2-api-config-management)-
+  attrs             | Dictionary   | **Required.** Set specific object 
attributes for this [object type](09-object-types.md#object-types).
+  ignore\_on\_error | Boolean      | **Optional.** Ignore object creation 
errors and return an HTTP 200 status instead.
 
 The object name must be specified as part of the URL path. For objects with 
composite names (e.g. services)
 the full name (e.g. `example.localdomain!http`) must be specified.
@@ -867,16 +868,16 @@
   Parameter    | Type      | Description
   -------------|-----------|--------------
   next\_check  | Timestamp | **Optional.** The next check will be run at this 
time. If omitted, the current time is used.
-  force\_check | Boolean   | **Optional.** Defaults to `false`. If enabled, 
the checks are executed regardless of time period restrictions and checks being 
disabled per object or on a global basis.
+  force        | Boolean   | **Optional.** Defaults to `false`. If enabled, 
the checks are executed regardless of time period restrictions and checks being 
disabled per object or on a global basis.
 
 In addition to these parameters a 
[filter](12-icinga2-api.md#icinga2-api-filters) must be provided. The valid 
types for this action are `Host` and `Service`.
 
 The example reschedules all services with the name "ping6" to immediately 
perform a check
 (`next_check` default), ignoring any time periods or whether active checks are
-allowed for the service (`force_check=true`).
+allowed for the service (`force=true`).
 
     $ curl -k -s -u root:icinga -H 'Accept: application/json' -X POST 
'https://localhost:5665/v1/actions/reschedule-check' \
-    -d '{ "type": "Service", "filter": "service.name==\"ping6\"", 
"force_check": true }' | python -m json.tool
+    -d '{ "type": "Service", "filter": "service.name==\"ping6\"", "force": 
true }' | python -m json.tool
 
     {
         "results": [
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/doc/20-script-debugger.md 
new/icinga2-2.8.4/doc/20-script-debugger.md
--- old/icinga2-2.8.2/doc/20-script-debugger.md 2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/doc/20-script-debugger.md 2018-04-25 15:11:31.000000000 
+0200
@@ -107,3 +107,56 @@
     <2> => $continue
 
 
+## Debugging API Filters <a id="script-debugger-api-filters"></a>
+
+Queries against the [Icinga 2 REST API](12-icinga2-api.md#icinga2-api) can use
+filters, just like available in `assign where` expressions. If these filters 
cause
+an internal error, they return an empty result to the caller.
+
+In order to analyse these server-side errors, you can use the script debugger.
+
+The following example tries filter for all host objects where the custom 
attribute
+`os` is set. There are various possibilities to check that, one of them would 
be
+`host.vars.os != ""`. Another idea is to use the 
[contains](18-library-reference.md#dictionary-contains) method on the custom
+attribute dictionary like this: `host.vars.contains("os")`.
+
+```
+$ curl -k -s -u root:icinga -H 'Accept: application/json' -H 
'X-HTTP-Method-Override: GET' \
+ -X POST 'https://localhost:5665/v1/objects/services' \
+ -d '{ "filter": "host.vars.contains(\"os\")", "attrs": [ "__name" ], "joins": 
[ "host.name", "host.vars" ], "pretty": true }'
+```
+
+This will fail on all hosts which don't have any custom attribute specified.
+
+```
+# icinga2 daemon -X
+
+Breakpoint encountered.
+Exception: Error: Argument is not a callable object.
+Location: in <API query>: 1:0-1:23
+You can inspect expressions (such as variables) by entering them at the prompt.
+To leave the debugger and continue the program use "$continue".
+
+<1> => this.host
+
+...
+
+       vars = null
+
+<2> => $continue
+```
+
+By definition, a type method can only be invoked on an actual object.
+
+In order to stay safe, add more checks to the API filter:
+
+- `host.vars && host.vars.contains("os")` or
+- `host.vars && typeof(host.vars) == Dictionary && host.vars.contains("os")`
+
+Example:
+
+```
+$ curl -k -s -u root:icinga -H 'Accept: application/json' -H 
'X-HTTP-Method-Override: GET' \
+ -X POST 'https://localhost:5665/v1/objects/services' \
+ -d '{ "filter": "host.vars && typeof(host.vars) == Dictionary && 
host.vars.contains(\"os\")", "attrs": [ "__name" ], "joins": [ "host.name", 
"host.vars" ], "pretty": true }'
+```
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/etc/initsystem/CMakeLists.txt 
new/icinga2-2.8.4/etc/initsystem/CMakeLists.txt
--- old/icinga2-2.8.2/etc/initsystem/CMakeLists.txt     2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/etc/initsystem/CMakeLists.txt     2018-04-25 
15:11:31.000000000 +0200
@@ -16,8 +16,6 @@
 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
 
 if(NOT WIN32)
-    set(ICINGA2_SYSCONFIGFILE 
"${CMAKE_INSTALL_FULL_SYSCONFDIR}/sysconfig/icinga2" CACHE PATH "where to store 
configuation for the init system, defaults to /etc/sysconfig/icinga2")
-
   configure_file(icinga2.sysconfig.cmake 
${CMAKE_CURRENT_BINARY_DIR}/initsystem/icinga2.sysconfig @ONLY)
   get_filename_component(ICINGA2_SYSCONFIGFILE_NAME ${ICINGA2_SYSCONFIGFILE} 
NAME)
   get_filename_component(ICINGA2_SYSCONFIGFILE_DIR ${ICINGA2_SYSCONFIGFILE} 
PATH)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/icinga-app/icinga.cpp 
new/icinga2-2.8.4/icinga-app/icinga.cpp
--- old/icinga2-2.8.2/icinga-app/icinga.cpp     2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/icinga-app/icinga.cpp     2018-04-25 15:11:31.000000000 
+0200
@@ -154,6 +154,13 @@
 
        Application::DeclareZonesDir(Application::GetSysconfDir() + 
"/icinga2/zones.d");
 
+#ifndef _WIN32
+       if (!Utility::PathExists(Application::GetSysconfigFile())) {
+               Log(LogWarning, "icinga-app")
+                       << "Sysconfig file '" << 
Application::GetSysconfigFile() << "' cannot be read. Using default values.";
+       }
+#endif /* _WIN32 */
+
        String icingaUser = Utility::GetFromSysconfig("ICINGA2_USER");
        if (icingaUser.IsEmpty())
                icingaUser = ICINGA_USER;
@@ -222,25 +229,6 @@
        ScriptGlobal::Set("BuildCompilerName", ICINGA_BUILD_COMPILER_NAME);
        ScriptGlobal::Set("BuildCompilerVersion", 
ICINGA_BUILD_COMPILER_VERSION);
 
-       String initconfig = Application::GetSysconfDir() + "/icinga2/init.conf";
-
-       if (Utility::PathExists(initconfig)) {
-               Expression *expression;
-               try {
-                       expression = ConfigCompiler::CompileFile(initconfig);
-
-                       ScriptFrame frame;
-                       expression->Evaluate(frame);
-               } catch (const std::exception& ex) {
-                       delete expression;
-
-                       Log(LogCritical, "config", DiagnosticInformation(ex));
-                       return EXIT_FAILURE;
-               }
-
-               delete expression;
-       }
-
        if (!autocomplete)
                Application::SetResourceLimits();
 
@@ -487,6 +475,7 @@
 
                        std::cout << visibleDesc << std::endl
                                << "Report bugs at 
<https://github.com/Icinga/icinga2>" << std::endl
+                               << "Get support: 
<https://www.icinga.com/support/>" << std::endl
                                << "Icinga home page: 
<https://www.icinga.com/>" << std::endl;
                        return EXIT_SUCCESS;
                }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/icinga2.spec 
new/icinga2-2.8.4/icinga2.spec
--- old/icinga2-2.8.2/icinga2.spec      2018-03-22 11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/icinga2.spec      1970-01-01 01:00:00.000000000 +0100
@@ -1,23 +0,0 @@
-#/******************************************************************************
-# * Icinga 2                                                                   
*
-# * Copyright (C) 2012-2017 Icinga Development Team (https://www.icinga.com/)  
*
-# *                                                                            
*
-# * This program is free software; you can redistribute it and/or              
*
-# * modify it under the terms of the GNU General Public License                
*
-# * as published by the Free Software Foundation; either version 2             
*
-# * of the License, or (at your option) any later version.                     
*
-# *                                                                            
*
-# * This program is distributed in the hope that it will be useful,            
*
-# * but WITHOUT ANY WARRANTY; without even the implied warranty of             
*
-# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the              
*
-# * GNU General Public License for more details.                               
*
-# *                                                                            
*
-# * You should have received a copy of the GNU General Public License          
*
-# * along with this program; if not, write to the Free Software Foundation     
*
-# * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.             
*
-# 
******************************************************************************/
-
-# The spec file was moved to https://github.com/Icinga/icinga-packaging
-
-%define revision 1
-Version: 2.8.2
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/base/application.cpp 
new/icinga2-2.8.4/lib/base/application.cpp
--- old/icinga2-2.8.2/lib/base/application.cpp  2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/base/application.cpp  2018-04-25 15:11:31.000000000 
+0200
@@ -197,7 +197,8 @@
                rl.rlim_max = rl.rlim_cur;
 
                if (setrlimit(RLIMIT_NOFILE, &rl) < 0)
-                       Log(LogNotice, "Application", "Could not adjust 
resource limit for open file handles (RLIMIT_NOFILE)");
+                       Log(LogWarning, "Application")
+                           << "Failed to adjust resource limit for open file 
handles (RLIMIT_NOFILE) with error \"" << strerror(errno) << "\"";
 #      else /* RLIMIT_NOFILE */
                Log(LogNotice, "Application", "System does not support 
adjusting the resource limit for open file handles (RLIMIT_NOFILE)");
 #      endif /* RLIMIT_NOFILE */
@@ -217,7 +218,8 @@
                rl.rlim_max = rl.rlim_cur;
 
                if (setrlimit(RLIMIT_NPROC, &rl) < 0)
-                       Log(LogNotice, "Application", "Could not adjust 
resource limit for number of processes (RLIMIT_NPROC)");
+                       Log(LogWarning, "Application")
+                           << "Failed adjust resource limit for number of 
processes (RLIMIT_NPROC) with error \"" << strerror(errno) << "\"";
 #      else /* RLIMIT_NPROC */
                Log(LogNotice, "Application", "System does not support 
adjusting the resource limit for number of processes (RLIMIT_NPROC)");
 #      endif /* RLIMIT_NPROC */
@@ -257,7 +259,8 @@
                        rl.rlim_cur = rl.rlim_max;
 
                if (setrlimit(RLIMIT_STACK, &rl) < 0)
-                       Log(LogNotice, "Application", "Could not adjust 
resource limit for stack size (RLIMIT_STACK)");
+                       Log(LogWarning, "Application")
+                           << "Failed adjust resource limit for stack size 
(RLIMIT_STACK) with error \"" << strerror(errno) << "\"";
                else if (set_stack_rlimit) {
                        char **new_argv = static_cast<char 
**>(malloc(sizeof(char *) * (argc + 2)));
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/base/timer.cpp 
new/icinga2-2.8.4/lib/base/timer.cpp
--- old/icinga2-2.8.2/lib/base/timer.cpp        2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/base/timer.cpp        2018-04-25 15:11:31.000000000 
+0200
@@ -266,7 +266,7 @@
 
                if (wait > 0.01) {
                        /* Wait for the next timer. */
-                       l_TimerCV.timed_wait(lock, 
boost::posix_time::milliseconds(wait * 1000));
+                       l_TimerCV.timed_wait(lock, 
boost::posix_time::milliseconds(long(wait * 1000)));
 
                        continue;
                }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/base/utility.cpp 
new/icinga2-2.8.4/lib/base/utility.cpp
--- old/icinga2-2.8.2/lib/base/utility.cpp      2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/base/utility.cpp      2018-04-25 15:11:31.000000000 
+0200
@@ -1958,6 +1958,9 @@
        if (sysconf.IsEmpty())
                return "";
 
+       if (!Utility::PathExists(sysconf))
+               return "";
+
        String cmdInner = ". " + EscapeShellArg(sysconf) + " 2>&1 
>/dev/null;echo \"$" + env + "\"";
        String cmd = "sh -c " + EscapeShellArg(cmdInner);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/checker/checkercomponent.cpp 
new/icinga2-2.8.4/lib/checker/checkercomponent.cpp
--- old/icinga2-2.8.2/lib/checker/checkercomponent.cpp  2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/checker/checkercomponent.cpp  2018-04-25 
15:11:31.000000000 +0200
@@ -130,7 +130,7 @@
 
                if (wait > 0) {
                        /* Wait for the next check. */
-                       m_CV.timed_wait(lock, 
boost::posix_time::milliseconds(wait * 1000));
+                       m_CV.timed_wait(lock, 
boost::posix_time::milliseconds(long(wait * 1000)));
 
                        continue;
                }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/cli/apiusercommand.cpp 
new/icinga2-2.8.4/lib/cli/apiusercommand.cpp
--- old/icinga2-2.8.2/lib/cli/apiusercommand.cpp        2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/cli/apiusercommand.cpp        2018-04-25 
15:11:31.000000000 +0200
@@ -56,19 +56,18 @@
  */
 int ApiUserCommand::Run(const boost::program_options::variables_map& vm, const 
std::vector<std::string>& ap) const
 {
-       String user, passwd, salt;
+       String passwd, salt;
        if (!vm.count("user") && !vm.count("oneline")) {
                Log(LogCritical, "cli", "Username (--user) must be specified.");
                return 1;
-       } else
-               user = vm["user"].as<std::string>();
+       }
 
        if (!vm.count("password")) {
                Log(LogCritical, "cli", "Password (--password) must be 
specified.");
                return 1;
        }
 
-       passwd = vm["passwd"].as<std::string>();
+       passwd = vm["password"].as<std::string>();
        salt = vm.count("salt") ? String(vm["salt"].as<std::string>()) : 
RandomString(8);
 
        if (salt.FindFirstOf('$') != String::NPos) {
@@ -83,11 +82,11 @@
        }
 
        if (vm.count("oneline"))
-               std::cout << '"' << hashedPassword << "\"\n";
+               std::cout << hashedPassword << std::endl;
        else {
                std::cout << "object ApiUser ";
 
-               ConfigWriter::EmitString(std::cout, user);
+               ConfigWriter::EmitString(std::cout, 
vm["user"].as<std::string>());
 
                std::cout << "{\n"
                        << "  password_hash = ";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/perfdata/elasticsearchwriter.cpp 
new/icinga2-2.8.4/lib/perfdata/elasticsearchwriter.cpp
--- old/icinga2-2.8.2/lib/perfdata/elasticsearchwriter.cpp      2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/perfdata/elasticsearchwriter.cpp      2018-04-25 
15:11:31.000000000 +0200
@@ -148,6 +148,7 @@
                                        Log(LogWarning, "ElasticsearchWriter")
                                            << "Ignoring invalid perfdata 
value: '" << val << "' for object '"
                                            << checkable->GetName() << "'.";
+                                       continue;
                                }
                        }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/perfdata/influxdbwriter.cpp 
new/icinga2-2.8.4/lib/perfdata/influxdbwriter.cpp
--- old/icinga2-2.8.2/lib/perfdata/influxdbwriter.cpp   2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/perfdata/influxdbwriter.cpp   2018-04-25 
15:11:31.000000000 +0200
@@ -308,6 +308,17 @@
        boost::algorithm::replace_all(result, "=", "\\=");
        boost::algorithm::replace_all(result, ",", "\\,");
        boost::algorithm::replace_all(result, " ", "\\ ");
+
+       // InfluxDB 'feature': although backslashes are allowed in keys they 
also act
+       // as escape sequences when followed by ',' or ' '.  When your tag is 
like
+       // 'metric=C:\' bad things happen.  Backslashes themselves cannot be 
escaped
+       // and through experimentation they also escape '='.  To be safe we 
replace
+       // trailing backslashes with and underscore.
+       // See https://github.com/influxdata/influxdb/issues/8587 for more info
+       size_t length = result.GetLength();
+       if (result[length - 1] == '\\')
+               result[length - 1] = '_';
+
        return result;
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/remote/apilistener.cpp 
new/icinga2-2.8.4/lib/remote/apilistener.cpp
--- old/icinga2-2.8.2/lib/remote/apilistener.cpp        2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/remote/apilistener.cpp        2018-04-25 
15:11:31.000000000 +0200
@@ -220,7 +220,7 @@
        ObjectImpl<ApiListener>::Start(runtimeCreated);
 
        {
-               boost::mutex::scoped_lock(m_LogLock);
+               boost::mutex::scoped_lock lock(m_LogLock);
                RotateLogFile();
                OpenLogFile();
        }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/remote/configpackageshandler.cpp 
new/icinga2-2.8.4/lib/remote/configpackageshandler.cpp
--- old/icinga2-2.8.2/lib/remote/configpackageshandler.cpp      2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/lib/remote/configpackageshandler.cpp      2018-04-25 
15:11:31.000000000 +0200
@@ -98,7 +98,9 @@
                boost::mutex::scoped_lock 
lock(ConfigPackageUtility::GetStaticMutex());
                ConfigPackageUtility::CreatePackage(packageName);
        } catch (const std::exception& ex) {
-               HttpUtility::SendJsonError(response, 500, "Could not create 
package.", "");
+               HttpUtility::SendJsonError(response, 500, "Could not create 
package.",
+                       HttpUtility::GetLastParameter(params, "verboseErrors") 
? DiagnosticInformation(ex) : "");
+               return;
        }
 
        result1->Set("code", 200);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/remote/eventqueue.cpp 
new/icinga2-2.8.4/lib/remote/eventqueue.cpp
--- old/icinga2-2.8.2/lib/remote/eventqueue.cpp 2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/remote/eventqueue.cpp 2018-04-25 15:11:31.000000000 
+0200
@@ -114,7 +114,7 @@
                        return result;
                }
 
-               if (!m_CV.timed_wait(lock, 
boost::posix_time::milliseconds(timeout * 1000)))
+               if (!m_CV.timed_wait(lock, 
boost::posix_time::milliseconds(long(timeout * 1000))))
                        return Dictionary::Ptr();
        }
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/remote/url.cpp 
new/icinga2-2.8.4/lib/remote/url.cpp
--- old/icinga2-2.8.2/lib/remote/url.cpp        2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/remote/url.cpp        2018-04-25 15:11:31.000000000 
+0200
@@ -208,6 +208,11 @@
        m_Query = query;
 }
 
+void Url::SetArrayFormatUseBrackets(bool useBrackets)
+{
+       m_ArrayFormatUseBrackets = useBrackets;
+}
+
 void Url::AddQueryElement(const String& name, const String& value)
 {
        auto it = m_Query.find(name);
@@ -276,8 +281,11 @@
                                        temp += "&";
 
                                temp += key;
-                               if (kv.second.size() > 1)
-                                       temp += "[]";
+
+                               if (m_ArrayFormatUseBrackets) {
+                                       if (kv.second.size() > 1)
+                                               temp += "[]";
+                               }
 
                                if (!s.IsEmpty())
                                        temp += "=" + Utility::EscapeString(s, 
ACQUERY_ENCODE, false);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/lib/remote/url.hpp 
new/icinga2-2.8.4/lib/remote/url.hpp
--- old/icinga2-2.8.2/lib/remote/url.hpp        2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/lib/remote/url.hpp        2018-04-25 15:11:31.000000000 
+0200
@@ -65,6 +65,7 @@
        void SetPort(const String& port);
        void SetPath(const std::vector<String>& path);
        void SetQuery(const std::map<String, std::vector<String> >& query);
+       void SetArrayFormatUseBrackets(bool useBrackets = true);
 
        void AddQueryElement(const String& name, const String& query);
        void SetQueryElements(const String& name, const std::vector<String>& 
query);
@@ -78,6 +79,7 @@
        String m_Port;
        std::vector<String> m_Path;
        std::map<String, std::vector<String> > m_Query;
+       bool m_ArrayFormatUseBrackets;
        String m_Fragment;
 
        bool ParseScheme(const String& scheme);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/plugins/check_nscp_api.cpp 
new/icinga2-2.8.4/plugins/check_nscp_api.cpp
--- old/icinga2-2.8.2/plugins/check_nscp_api.cpp        2018-03-22 
11:26:19.000000000 +0100
+++ new/icinga2-2.8.4/plugins/check_nscp_api.cpp        2018-04-25 
15:11:31.000000000 +0200
@@ -17,7 +17,7 @@
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.             *
 ******************************************************************************/
 
-#define VERSION "1.0.0"
+#define VERSION "1.0.1"
 
 #include "remote/httpclientconnection.hpp"
 #include "remote/httprequest.hpp"
@@ -88,9 +88,13 @@
 
                // Url() will call Utillity::UnescapeString() which will thrown 
an exception if it finds a lonely %
                req->RequestUrl = new Url(endpoint);
+
+               // NSClient++ uses `time=1m&time=5m` instead of 
`time[]=1m&time[]=5m`
+               req->RequestUrl->SetArrayFormatUseBrackets(false);
+
                req->AddHeader("password", password);
                if (l_Debug)
-                       std::cout << "Sending request to 'https://"; << host << 
":" << port << req->RequestUrl->Format() << "'\n";
+                       std::cout << "Sending request to 'https://"; << host << 
":" << port << req->RequestUrl->Format(false, false) << "'\n";
 
                // Submits the request. The 'ResultHttpCompletionCallback' is 
called once the HttpRequest receives an answer,
                // which then sets 'ready' to true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/icinga2-2.8.2/test/remote-url.cpp 
new/icinga2-2.8.4/test/remote-url.cpp
--- old/icinga2-2.8.2/test/remote-url.cpp       2018-03-22 11:26:19.000000000 
+0100
+++ new/icinga2-2.8.4/test/remote-url.cpp       2018-04-25 15:11:31.000000000 
+0200
@@ -96,6 +96,14 @@
 
        url = new Url("/");
        BOOST_CHECK(url->Format(false, false) == "/");
+
+       url = new 
Url("https://nsclient:8443/query/check_cpu?time%5B%5D=1m&time=5m&time%5B%5D=15m";);
+       url->SetArrayFormatUseBrackets(false);
+       BOOST_CHECK(new Url(url->Format(false, false)));
+
+       url = new Url("https://icinga2/query?a[]=1&a[]=2&a[]=3";);
+       url->SetArrayFormatUseBrackets(true);
+       BOOST_CHECK(new Url(url->Format(false, false)));
 }
 
 BOOST_AUTO_TEST_CASE(illegal_legal_strings)


Reply via email to