[Pkg-nagios-changes] [pkg-nagios] r1659 - in nagios-plugins/trunk/debian: . patches

Jan Wagner waja at alioth.debian.org
Thu May 14 19:54:25 UTC 2009


tags 528686 pending
thanks

Author: waja
Date: 2009-05-14 19:54:24 +0000 (Thu, 14 May 2009)
New Revision: 1659

Added:
   nagios-plugins/trunk/debian/patches/43_check_ntp_segfaults.dpatch
Modified:
   nagios-plugins/trunk/debian/changelog
   nagios-plugins/trunk/debian/patches/00list
Log:
fix buffer overflow

Modified: nagios-plugins/trunk/debian/changelog
===================================================================
--- nagios-plugins/trunk/debian/changelog	2009-05-12 20:31:17 UTC (rev 1658)
+++ nagios-plugins/trunk/debian/changelog	2009-05-14 19:54:24 UTC (rev 1659)
@@ -3,6 +3,8 @@
   * add trailing $ to check_httpname, thanks Daniel Pocock (Closes: #524629)
   * add informations into README.Debian how to use plugins (Closes: #525168)
   * add check_nscp which uses the default port of NSClient++ (Closes: #528262)
+  * add 43_check_ntp_segfaults.dpatch to fix buffer overflow in check_ntp and
+    check_ntp_peer, thanks to Andreas Olsson (Closes: #528686)
 
  -- Jan Wagner <waja at cyconet.org>  Sun, 01 Feb 2009 03:19:57 +0100
 

Modified: nagios-plugins/trunk/debian/patches/00list
===================================================================
--- nagios-plugins/trunk/debian/patches/00list	2009-05-12 20:31:17 UTC (rev 1658)
+++ nagios-plugins/trunk/debian/patches/00list	2009-05-14 19:54:24 UTC (rev 1659)
@@ -17,4 +17,5 @@
 40_check_http_status_line.dpatch
 41_check_http_fix_http_header.dpatch
 42_check_ups_logoutfix.dpatch
+43_check_ntp_segfaults.dpatch
 50_misc_typos.dpatch

Added: nagios-plugins/trunk/debian/patches/43_check_ntp_segfaults.dpatch
===================================================================
--- nagios-plugins/trunk/debian/patches/43_check_ntp_segfaults.dpatch	                        (rev 0)
+++ nagios-plugins/trunk/debian/patches/43_check_ntp_segfaults.dpatch	2009-05-14 19:54:24 UTC (rev 1659)
@@ -0,0 +1,32 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 43_check_ntp_segfaults.dpatch by Thierry Carrez <thierry.carrez at ubuntu.com>
+##
+## DP: Fixes check_ntp and check_ntp_peer segfaults (LP: #291265)
+## Patch originally from Thomas Guyot, extracted from upstream SVN at:
+## http://nagiosplug.svn.sourceforge.net/viewvc/nagiosplug?view=rev&revision=2086
+
+ at DPATCH@
+diff -urNad nagios-plugins-1.4.12~/plugins/check_ntp.c nagios-plugins-1.4.12/plugins/check_ntp.c
+--- nagios-plugins-1.4.12~/plugins/check_ntp.c	2008-05-07 10:02:42.000000000 +0000
++++ nagios-plugins-1.4.12/plugins/check_ntp.c	2008-11-19 16:38:06.000000000 +0000
+@@ -198,7 +198,7 @@
+ /* NTP control message header is 12 bytes, plus any data in the data
+  * field, plus null padding to the nearest 32-bit boundary per rfc.
+  */
+-#define SIZEOF_NTPCM(m) (12+ntohs(m.count)+((m.count)?4-(ntohs(m.count)%4):0))
++#define SIZEOF_NTPCM(m) (12+ntohs(m.count)+((ntohs(m.count)%4)?4-(ntohs(m.count)%4):0))
+ 
+ /* finally, a little helper or two for debugging: */
+ #define DBG(x) do{if(verbose>1){ x; }}while(0);
+diff -urNad nagios-plugins-1.4.12~/plugins/check_ntp_peer.c nagios-plugins-1.4.12/plugins/check_ntp_peer.c
+--- nagios-plugins-1.4.12~/plugins/check_ntp_peer.c	2008-05-07 10:02:42.000000000 +0000
++++ nagios-plugins-1.4.12/plugins/check_ntp_peer.c	2008-11-19 16:38:06.000000000 +0000
+@@ -130,7 +130,7 @@
+ /* NTP control message header is 12 bytes, plus any data in the data
+  * field, plus null padding to the nearest 32-bit boundary per rfc.
+  */
+-#define SIZEOF_NTPCM(m) (12+ntohs(m.count)+((m.count)?4-(ntohs(m.count)%4):0))
++#define SIZEOF_NTPCM(m) (12+ntohs(m.count)+((ntohs(m.count)%4)?4-(ntohs(m.count)%4):0))
+ 
+ /* finally, a little helper or two for debugging: */
+ #define DBG(x) do{if(verbose>1){ x; }}while(0);




More information about the Pkg-nagios-changes mailing list