Hello community,
here is the log from the commit of package nagios-nsca
checked in at Thu Dec 7 21:11:11 CET 2006.
--------
--- nagios-nsca/nagios-nsca.changes 2006-10-10 11:57:54.000000000 +0200
+++ /mounts/work_src_done/STABLE/nagios-nsca/nagios-nsca.changes 2006-12-01 13:12:16.000000000 +0100
@@ -1,0 +2,14 @@
+Fri Dec 1 12:59:22 CET 2006 - tsieden@suse.de
+
+- update to version 2.6
+ * spec file fix
+ * segfault fix in encryption library cleanup
+ * daemon now exits with an error if it can't drop privileges
+ * added chroot support (Sean Finney)
+ * added support for writing a PID file
+ * added support for reloading config files with SIGHUP
+ * removed obsolete patches which are included in upstream now
+
+- fix NscaBin location in init script
+
+-------------------------------------------------------------------
Old:
----
nagios-nsca.encrypt-cleanup.patch
nsca-2.5.tar.bz2
New:
----
nsca-2.6.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ nagios-nsca.spec ++++++
--- /var/tmp/diff_new_pack.S89hBv/_old 2006-12-07 21:10:47.000000000 +0100
+++ /var/tmp/diff_new_pack.S89hBv/_new 2006-12-07 21:10:47.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package nagios-nsca (Version 2.5)
+# spec file for package nagios-nsca (Version 2.6)
#
# Copyright (c) 2006 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
@@ -13,10 +13,10 @@
Name: nagios-nsca
BuildRequires: libmcrypt-devel nagios tcpd-devel
Summary: The Nagios Service Check Acceptor
-Version: 2.5
-Release: 20
+Version: 2.6
+Release: 1
URL: http://www.nagios.org/
-License: GPL
+License: GNU General Public License (GPL)
Group: System/Monitoring
Autoreqprov: on
Requires: nagios
@@ -27,8 +27,7 @@
Patch1: nagios-nsca.abuild.patch
Patch2: nagios-nsca.xinetd.patch
Patch3: nagios-nsca.spooldir.patch
-Patch4: nagios-nsca.encrypt-cleanup.patch
-Patch5: nagios-nsca.send_nsca.formatstring.patch
+Patch4: nagios-nsca.send_nsca.formatstring.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@@ -44,11 +43,10 @@
%prep
%setup -n nsca-%{version}
-%patch1 -p1
-%patch2 -p1
-%patch3 -p1
+%patch1
+%patch2
+%patch3
%patch4 -p1
-%patch5 -p1
%build
%{?suse_update_config:%{suse_update_config}}
@@ -102,6 +100,16 @@
%doc Changelog README SECURITY LEGAL
%changelog -n nagios-nsca
+* Fri Dec 01 2006 - tsieden@suse.de
+- update to version 2.6
+ * spec file fix
+ * segfault fix in encryption library cleanup
+ * daemon now exits with an error if it can't drop privileges
+ * added chroot support (Sean Finney)
+ * added support for writing a PID file
+ * added support for reloading config files with SIGHUP
+ * removed obsolete patches which are included in upstream now
+- fix NscaBin location in init script
* Tue Oct 10 2006 - olh@suse.de
- fix send_nsca segfault with -c and -d options
* Thu Feb 02 2006 - stark@suse.de
++++++ nagios-nsca.abuild.patch ++++++
--- /var/tmp/diff_new_pack.S89hBv/_old 2006-12-07 21:10:47.000000000 +0100
+++ /var/tmp/diff_new_pack.S89hBv/_new 2006-12-07 21:10:47.000000000 +0100
@@ -1,12 +1,6 @@
----
- src/nsca.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-Index: nsca-2.5/src/nsca.c
-===================================================================
---- nsca-2.5.orig/src/nsca.c
-+++ nsca-2.5/src/nsca.c
-@@ -555,6 +555,7 @@ static int find_rhand(int fd){
+--- src/nsca.c 2006-04-06 23:19:30.000000000 +0200
++++ src/nsca.c 2006-12-01 12:24:18.000000000 +0100
+@@ -601,6 +601,7 @@
/* we couldn't find the read handler */
syslog(LOG_ERR, "Handler stack corrupt - aborting");
do_exit(STATE_CRITICAL);
@@ -14,7 +8,7 @@
}
-@@ -571,6 +572,7 @@ static int find_whand(int fd){
+@@ -617,6 +618,7 @@
/* we couldn't find the write handler */
syslog(LOG_ERR, "Handler stack corrupt - aborting");
do_exit(STATE_CRITICAL);
++++++ nagios-nsca.spooldir.patch ++++++
--- /var/tmp/diff_new_pack.S89hBv/_old 2006-12-07 21:10:47.000000000 +0100
+++ /var/tmp/diff_new_pack.S89hBv/_new 2006-12-07 21:10:47.000000000 +0100
@@ -1,12 +1,15 @@
----
- sample-config/nsca.cfg.in | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-Index: nsca-2.5/sample-config/nsca.cfg.in
-===================================================================
---- nsca-2.5.orig/sample-config/nsca.cfg.in
-+++ nsca-2.5/sample-config/nsca.cfg.in
-@@ -57,7 +57,7 @@ debug=0
+--- sample-config/nsca.cfg.in 2006-04-06 23:19:30.000000000 +0200
++++ sample-config/nsca.cfg.in 2006-12-01 12:31:39.000000000 +0100
+@@ -61,7 +61,7 @@
+ # NOTE: if you specify this option, the command file will be opened
+ # relative to this directory.
+
+-#nsca_chroot=/var/run/nagios/rw
++#nsca_chroot=/var/run/nagios
+
+
+
+@@ -78,7 +78,7 @@
# This is the location of the Nagios command file that the daemon
# should write all service check results that it receives.
@@ -15,7 +18,7 @@
# ALTERNATE DUMP FILE
-@@ -70,7 +70,7 @@ command_file=@localstatedir@/rw/nagios.c
+@@ -91,7 +91,7 @@
# it starts Nagios. Or you may simply choose to ignore any
# check results received while Nagios was not running...
++++++ nagios-nsca.xinetd.patch ++++++
--- /var/tmp/diff_new_pack.S89hBv/_old 2006-12-07 21:10:47.000000000 +0100
+++ /var/tmp/diff_new_pack.S89hBv/_new 2006-12-07 21:10:47.000000000 +0100
@@ -1,11 +1,5 @@
----
- sample-config/nsca.xinetd.in | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-Index: nsca-2.5/sample-config/nsca.xinetd.in
-===================================================================
---- nsca-2.5.orig/sample-config/nsca.xinetd.in
-+++ nsca-2.5/sample-config/nsca.xinetd.in
+--- sample-config/nsca.xinetd.in 2003-10-16 01:17:46.000000000 +0200
++++ sample-config/nsca.xinetd.in 2006-12-01 12:39:20.000000000 +0100
@@ -1,15 +1,17 @@
-# default: on
+# default: off
@@ -14,8 +8,8 @@
{
flags = REUSE
socket_type = stream
-+ type = UNLISTED
-+ port = @nsca_port@
++ type = UNLISTED
++ port = @nsca_port@
wait = no
user = @nsca_user@
group = @nsca_grp@
@@ -25,5 +19,5 @@
- disable = no
- only_from = 127.0.0.1
+ disable = yes
-+ #only_from = 127.0.0.1
++# only_from = 127.0.0.1
}
++++++ nsca-2.5.tar.bz2 -> nsca-2.6.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/Changelog new/nsca-2.6/Changelog
--- old/nsca-2.5/Changelog 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/Changelog 2006-04-06 23:19:30.000000000 +0200
@@ -3,6 +3,16 @@
**************
+2.6 - 04/06/2006
+----------------
+- Spec file fix
+- Segfault fix in encryption library cleanup
+- Daemon now exits with an error if it can't drop privileges
+- Added chroot support (Sean Finney)
+- Added support for writing a PID file
+- Added support for reloading config files with SIGHUP
+
+
2.5 - 01/21/2006
----------------
- Native TCP wrapper support in daemon mode
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/configure new/nsca-2.6/configure
--- old/nsca-2.5/configure 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/configure 2006-04-06 23:19:30.000000000 +0200
@@ -1288,9 +1288,9 @@
PKG_NAME=nsca
-PKG_VERSION="2.5"
+PKG_VERSION="2.6"
PKG_HOME_URL="http://www.nagios.org/"
-PKG_REL_DATE="01-21-2006"
+PKG_REL_DATE="04-06-2006"
ac_aux_dir=
for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/configure.in new/nsca-2.6/configure.in
--- old/nsca-2.5/configure.in 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/configure.in 2006-04-06 23:19:30.000000000 +0200
@@ -9,9 +9,9 @@
AC_PREFIX_DEFAULT(/usr/local/nagios)
PKG_NAME=nsca
-PKG_VERSION="2.5"
+PKG_VERSION="2.6"
PKG_HOME_URL="http://www.nagios.org/"
-PKG_REL_DATE="01-21-2006"
+PKG_REL_DATE="04-06-2006"
dnl Figure out how to invoke "install" and what install options to use.
AC_PROG_INSTALL
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/include/common.h new/nsca-2.6/include/common.h
--- old/nsca-2.5/include/common.h 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/include/common.h 2006-04-06 23:19:30.000000000 +0200
@@ -24,8 +24,8 @@
#include "config.h"
-#define PROGRAM_VERSION "2.5"
-#define MODIFICATION_DATE "01-21-2006"
+#define PROGRAM_VERSION "2.6"
+#define MODIFICATION_DATE "04-06-2006"
#define OK 0
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/include/nsca.h new/nsca-2.6/include/nsca.h
--- old/nsca-2.5/include/nsca.h 1970-01-01 01:00:00.000000000 +0100
+++ new/nsca-2.6/include/nsca.h 2006-04-06 23:20:43.000000000 +0200
@@ -0,0 +1,56 @@
+/************************************************************************
+ *
+ * NSCA.H - NSCA Include File
+ * Copyright (c) 1999-2006 Ethan Galstad (nagios@nagios.org)
+ * Last Modified: 04-03-2006
+ *
+ * License:
+ *
+ * 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., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ ************************************************************************/
+
+struct handler_entry{
+ void (*handler)(int, void *);
+ void *data;
+ int fd;
+ };
+
+
+static void handle_events(void);
+static void wait_for_connections(void);
+static void handle_connection(int,void *);
+static void accept_connection(int,void *);
+static void handle_connection_read(int,void *);
+static void install_child_handler(void);
+
+static int process_arguments(int,char **);
+static int read_config_file(char *);
+
+static int open_command_file(void);
+static void close_command_file(void);
+static int write_check_result(char *,char *,int,char *,time_t);
+
+static int get_user_info(const char *,uid_t *);
+static int get_group_info(const char *,gid_t *);
+static int drop_privileges(const char *,uid_t,gid_t);
+static void do_chroot(void);
+static void do_exit(int);
+
+static int write_pid_file(uid_t,gid_t);
+static int remove_pid_file(void);
+
+void sighandler(int);
+
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/nsca.spec new/nsca-2.6/nsca.spec
--- old/nsca-2.5/nsca.spec 2004-02-03 02:27:54.000000000 +0100
+++ new/nsca-2.6/nsca.spec 2006-04-06 23:19:30.000000000 +0200
@@ -1,5 +1,5 @@
%define name nsca
-%define version 2.4
+%define version 2.6
%define release 1
%define nsusr nagios
%define nsgrp nagios
@@ -18,7 +18,7 @@
Name: %{name}
Version: %{version}
Release: %{release}
-Copyright: GPL
+License: GPL
Group: Application/System
Source0: %{name}-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-buildroot
@@ -117,9 +117,9 @@
%install
[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
-install -b -D -m 0644 nsca.cfg ${RPM_BUILD_ROOT}/etc/nagios/nsca.cfg
-install -b -D -m 0644 send_nsca.cfg ${RPM_BUILD_ROOT}/etc/nagios/send_nsca.cfg
-install -b -D -m 0644 nsca.xinetd ${RPM_BUILD_ROOT}/etc/xined.d/nsca
+install -b -D -m 0644 sample-config/nsca.cfg ${RPM_BUILD_ROOT}/etc/nagios/nsca.cfg
+install -b -D -m 0644 sample-config/send_nsca.cfg ${RPM_BUILD_ROOT}/etc/nagios/send_nsca.cfg
+install -b -D -m 0644 sample-config/nsca.xinetd ${RPM_BUILD_ROOT}/etc/xined.d/nsca
install -b -D -m 0755 src/nsca ${RPM_BUILD_ROOT}/usr/sbin/nsca
install -b -D -m 0755 src/send_nsca ${RPM_BUILD_ROOT}/usr/bin/send_nsca
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/sample-config/nsca.cfg.in new/nsca-2.6/sample-config/nsca.cfg.in
--- old/nsca-2.5/sample-config/nsca.cfg.in 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/sample-config/nsca.cfg.in 2006-04-06 23:19:30.000000000 +0200
@@ -2,10 +2,18 @@
# Sample NSCA Daemon Config File
# Written by: Ethan Galstad (nagios@nagios.org)
#
-# Last Modified: 01-21-2006
+# Last Modified: 04-03-2006
####################################################
+# PID FILE
+# The name of the file in which the NSCA daemon should write it's process ID
+# number. The file is only written if the NSCA daemon is started by the root
+# user as a single- or multi-process daemon.
+
+pid_file=/var/run/nsca.pid
+
+
# PORT NUMBER
# Port number we should wait for connections on.
@@ -44,6 +52,19 @@
+# NSCA CHROOT
+# If specified, determines a directory into which the nsca daemon
+# will perform a chroot(2) operation before dropping its privileges.
+# for the security conscious this can add a layer of protection in
+# the event that the nagios daemon is compromised.
+#
+# NOTE: if you specify this option, the command file will be opened
+# relative to this directory.
+
+#nsca_chroot=/var/run/nagios/rw
+
+
+
# DEBUGGING OPTION
# This option determines whether or not debugging
# messages are logged to the syslog facility.
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/nsca-2.5/src/nsca.c new/nsca-2.6/src/nsca.c
--- old/nsca-2.5/src/nsca.c 2006-01-22 01:14:55.000000000 +0100
+++ new/nsca-2.6/src/nsca.c 2006-04-06 23:19:30.000000000 +0200
@@ -4,7 +4,7 @@
* Copyright (c) 2000-2006 Ethan Galstad (nagios@nagios.org)
* License: GPL v2
*
- * Last Modified: 01-21-2006
+ * Last Modified: 04-06-2006
*
* Command line: NSCA -c