diff options
| -rw-r--r-- | debian/changelog | 20 | ||||
| -rw-r--r-- | debian/control | 16 | ||||
| -rw-r--r-- | debian/copyright | 29 | ||||
| -rw-r--r-- | debian/lsm.1 | 37 | ||||
| -rwxr-xr-x | debian/lsm.init | 77 | ||||
| -rw-r--r-- | debian/lsm.install | 1 | ||||
| -rw-r--r-- | debian/lsm.manpages | 1 | ||||
| -rw-r--r-- | debian/lsm.postinst | 46 | ||||
| -rw-r--r-- | debian/lsm.sgml | 158 | ||||
| -rw-r--r-- | debian/patches/fix_misspell.patch | 29 | ||||
| -rw-r--r-- | debian/patches/hardening_improve.patch | 50 | ||||
| -rw-r--r-- | debian/patches/install_target.patch | 59 | ||||
| -rw-r--r-- | debian/patches/series | 4 | ||||
| -rw-r--r-- | debian/patches/source_relative_path.patch | 109 | ||||
| -rwxr-xr-x | debian/rules | 21 | ||||
| -rw-r--r-- | debian/source/format | 1 | ||||
| -rw-r--r-- | debian/upstream/changelog | 751 | ||||
| -rw-r--r-- | debian/watch | 2 |
18 files changed, 1411 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..eba5e15 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,20 @@ +lsm (1.0.4-2) unstable; urgency=medium + + * Updated build-depends (Closes: #958635) + * Bumped Standards-Version to 5.4.0. + * Updated DH compat version to 12. + * Updated maintainer e-mail address. + * Removed unused patch, scripts_path.path file. + + + -- Lucas de Castro Borges <lucas@gnuabordo.com.br> Sun, 13 Sep 2020 15:13:02 +0000 + +lsm (1.0.4-1) unstable; urgency=medium + + * Initial release (Closes: #518165) + * debian/patches/ + - source_relative_path.patch: Use macros instead of static paths. + - hardening_improve.patch: Added hardening flags in Makefile. + - install_target.patch: Added PREFIX and set targets point up to PREFIX. + + -- Lucas de Castro Borges <lucascastroborges@gmail.com> Mon, 02 May 2016 23:18:50 -0300 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..23750a8 --- /dev/null +++ b/debian/control @@ -0,0 +1,16 @@ +Source: lsm +Section: utils +Priority: optional +Maintainer: Lucas de Castro Borges <lucas@gnuabordo.com.br> +Build-Depends: debhelper (>=9.2), debhelper-compat (=12), docbook-to-man +Standards-Version: 4.5.0 +Homepage: http://lsm.foobar.fi/ + +Package: lsm +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Link connectivity monitor tool + Provide a Link Status Monitor, It can be used to monitor Linux router/firewall + connectivity and if router/firewall has multiple connections it can change + routing when an up/down event happens by utilizing external script. + This package is highly influenced by fping and iputils arping. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..ea865d6 --- /dev/null +++ b/debian/copyright @@ -0,0 +1,29 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: lsm +Source: http://lsm.foobar.fi/download/ + +Files: * +Copyright: 2009-2016 Mika Ilmaranta <ilmis@nullnet.fi> + 2009-2015 Tuomo Soini <tis@foobar.fi> +License: GPL-2 + +Files: debian/* +Copyright: 2016 Lucas de Castro Borges <lucascastroborges@gmail.com> +License: GPL-2 + +License: GPL-2 + 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; only version 2 of + the License is valid for this program. + . + This package 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, see <https://www.gnu.org/licenses/> + . + On Debian systems, the complete text of the GNU General + Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". diff --git a/debian/lsm.1 b/debian/lsm.1 new file mode 100644 index 0000000..5b9f1a4 --- /dev/null +++ b/debian/lsm.1 @@ -0,0 +1,37 @@ +.TH "lsm" "1" +.SH "NAME" +lsm \(em Monitor connectivity status +.SH "SYNOPSIS" +.PP +\fBlsm\fR [\fBOPTIONS...\fP] +.SH "DESCRIPTION" +.PP +LSM is a link connectivity monitor tool. +.PP +LSM can be used to monitor a Linux router/firewall connectivity. +If it has multiple connections it can change routing when an +up/down event happens by utilizing external script. +.SH "OPTIONS" +.IP "\fB-h\fP | \fB\-\-help\fP " 10 +Show summary of options. +.IP "\fB-v\fP \fB\-\-version\fP " 10 +Show version of program. +.IP "\fB-c\fP \fB\-\-config FILE\fP " 10 +Specify an alternative config file instead of the default one. +.IP "\fB-p\fP \fB\-\-pidfile FILE\fP " 10 +Specify an alternative pid file instead of the default one. +.IP "\fB-f\fP \fB\-\-no-fork\fP " 10 +Make instance independent of others one already running. +.SH "AUTHOR" +.PP +This manual page was written by Lucas de Castro Borges lucascastroborges@gmail.com for +the \fBDebian\fP system (and may be used by others). Permission is +granted to copy, distribute and/or modify this document under +the terms of the GNU General Public License, Version 2 any +later version published by the Free Software Foundation. + +.PP +On Debian systems, the complete text of the GNU General Public +License can be found in /usr/share/common-licenses/GPL. + +.\" created by instant / docbook-to-man diff --git a/debian/lsm.init b/debian/lsm.init new file mode 100755 index 0000000..4a9c966 --- /dev/null +++ b/debian/lsm.init @@ -0,0 +1,77 @@ +#!/bin/sh +# kFreeBSD do not accept scripts as interpreters, using #!/bin/sh and sourcing. +#if [ true != "$INIT_D_SCRIPT_SOURCED" ] ; then +# set "$0" "$@"; INIT_D_SCRIPT_SOURCED=true . /lib/init/init-d-script +#fi +### BEGIN INIT INFO +# Provides: lsm +# Required-Start: $remote_fs $syslog +# Required-Stop: $remote_fs $syslog +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: Monitor Link connection. +# Description: +# <...> +# <...> +### END INIT INFO + +# Author: Lucas de Castro Borges <lucascastroborges@gmail.com> +NAME=lsm +DESC="Link Monitor" +DAEMON=/usr/sbin/lsm +PIDFILE=/var/run/$NAME.pid +CONFIG=/etc/lsm/lsm.conf + +PATH=/sbin:/bin:/usr/sbin:/usr/bin + +. /lib/lsb/init-functions + +if [ ! -x $DAEMON ]; then + log_daemon_msg "lsm" "exectuble missing" + log_progress_msg "not starting" + log_end_msg 1 +fi + +if [ ! -r $CONFIG ]; then + log_daemon_msg "config file missing - not starting" + log_end_msg 1 +fi + +do_start() { + start-stop-daemon --start --quiet -p $PIDFILE -x $DAEMON -- --config $CONFIG +} +do_stop() { + start-stop-daemon --stop --quiet -p $PIDFILE -x $DAEMON -- --config $CONFIG +} + +case "$1" in + start) + log_daemon_msg "Starting Link Monitor." "lsm" + do_start + case "$?" in + 0) log_end_msg 0 ;; + 1) log_progress_msg "Already started" + log_end_msg 0 ;; + *) log_end_msg 1 ;; + esac + ;; + stop) + log_daemon_msg "Stopping Link Monitor." "lsm" + do_stop + case "$?" in + 0) rm $PIDFILE + log_end_msg 0 ;; + 1) log_progress_msg "Already stopped" + log_end_msg 0 ;; + *) log_end_msg 1 ;; + esac + + ;; + status) + status_of_proc -p $PIDFILE $DAEMON $NAME && exit 0 || exit $? + ;; + *) + program_name=$0 + echo "Usage: ${program_name} {start|stop|status|restart}" + ;; +esac diff --git a/debian/lsm.install b/debian/lsm.install new file mode 100644 index 0000000..3fe34fe --- /dev/null +++ b/debian/lsm.install @@ -0,0 +1 @@ +lsm.service /lib/systemd/system/ diff --git a/debian/lsm.manpages b/debian/lsm.manpages new file mode 100644 index 0000000..c7ce619 --- /dev/null +++ b/debian/lsm.manpages @@ -0,0 +1 @@ +debian/lsm.1 diff --git a/debian/lsm.postinst b/debian/lsm.postinst new file mode 100644 index 0000000..82397a6 --- /dev/null +++ b/debian/lsm.postinst @@ -0,0 +1,46 @@ +#!/bin/sh +# postinst script for lsm +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * <postinst> `configure' <most-recently-configured-version> +# * <old-postinst> `abort-upgrade' <new version> +# * <conflictor's-postinst> `abort-remove' `in-favour' <package> +# <new-version> +# * <postinst> `abort-remove' +# * <deconfigured's-postinst> `abort-deconfigure' `in-favour' +# <failed-install-package> <version> `removing' +# <conflicting-package> <version> +# for details, see https://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + configure) + + echo "|===================================================|" + echo "| |" + echo "| Edit /etc/lsm/lsm.conf to setup lsm |" + echo "| and run invoke-rc.d lsm start to get lsm running |" + echo "| |" + echo "| ==================================================|" + exit 0 + ;; + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/debian/lsm.sgml b/debian/lsm.sgml new file mode 100644 index 0000000..c57e269 --- /dev/null +++ b/debian/lsm.sgml @@ -0,0 +1,158 @@ +<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [ + +<!-- Process this file with docbook-to-man to generate an nroff manual + page: `docbook-to-man manpage.sgml > manpage.1'. You may view + the manual page with: `docbook-to-man manpage.sgml | nroff -man | + less'. A typical entry in a Makefile or Makefile.am is: + +manpage.1: manpage.sgml + docbook-to-man $< > $@ + + + The docbook-to-man binary is found in the docbook-to-man package. + Please remember that if you create the nroff version in one of the + debian/rules file targets (such as build), you will need to include + docbook-to-man in your Build-Depends control field. + + --> + + <!-- Fill in your name for FIRSTNAME and SURNAME. --> + <!ENTITY dhfirstname "<firstname>Lucas</firstname>"> + <!ENTITY dhsurname "<surname>de Castro Borges</surname>"> + <!-- Please adjust the date whenever revising the manpage. --> + <!ENTITY dhdate "<date>May 9 2016</date>"> + <!-- SECTION should be 1-8, maybe w/ subsection other parameters are + allowed: see man(7), man(1). --> + <!ENTITY dhsection "<manvolnum>1</manvolnum>"> + <!ENTITY dhemail "<email>lucascastroborges@gmail.com</email>"> + <!ENTITY dhusername "Lucas de Castro Borges"> + <!ENTITY dhucpackage "<refentrytitle>lsm</refentrytitle>"> + <!ENTITY dhpackage "lsm"> + + <!ENTITY debian "<productname>Debian</productname>"> + <!ENTITY gnu "<acronym>GNU</acronym>"> + <!ENTITY gpl "&gnu; <acronym>GPL</acronym>"> +]> + +<refentry> + <refentryinfo> + <address> + &dhemail; + </address> + <author> + &dhfirstname; + &dhsurname; + </author> + <copyright> + <year>2003</year> + <holder>&dhusername;</holder> + </copyright> + &dhdate; + </refentryinfo> + <refmeta> + &dhucpackage; + + &dhsection; + </refmeta> + <refnamediv> + <refname>&dhpackage;</refname> + + <refpurpose>Monitor connectivity status</refpurpose> + </refnamediv> + <refsynopsisdiv> + <cmdsynopsis> + <command>&dhpackage;</command> + + <arg><option>OPTIONS...</option></arg> + + </cmdsynopsis> + </refsynopsisdiv> + <refsect1> + <title>DESCRIPTION</title> + + <para>LSM is a link connectivity monitor tool.</para> + + <para>LSM can be used to monitor a Linux router/firewall connectivity. + If it has multiple connections it can change routing when an + up/down event happens by utilizing external script.</para> + + </refsect1> + <refsect1> + <title>OPTIONS</title> + + <variablelist> + + <varlistentry> + <term><option>-h</option> | <option>--help</option> + </term> + <listitem> + <para>Show summary of options.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>-v</option> <option>--version</option> + </term> + <listitem> + <para>Show version of program.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>-c</option> <option>--config FILE</option> + </term> + <listitem> + <para>Specify an alternative config file instead of the default one.</para> + </listitem> + </varlistentry> + + <varlistentry> + <term><option>-p</option> <option>--pidfile FILE</option> + </term> + <listitem> + <para>Specify an alternative pid file instead of the default one.</para> + </listitem> + </varlistentry> + <varlistentry> + <term><option>-f</option> <option>--no-fork</option> + </term> + <listitem> + <para>Make instance independent of others one already running.</para> + </listitem> + </varlistentry> + </variablelist> + + </refsect1> + <refsect1> + <title>AUTHOR</title> + + <para>This manual page was written by &dhusername; &dhemail; for + the &debian; system (and may be used by others). Permission is + granted to copy, distribute and/or modify this document under + the terms of the &gnu; General Public License, Version 2 any + later version published by the Free Software Foundation. + </para> + <para> + On Debian systems, the complete text of the GNU General Public + License can be found in /usr/share/common-licenses/GPL. + </para> + + </refsect1> +</refentry> + +<!-- Keep this comment at the end of the file +Local variables: +mode: sgml +sgml-omittag:t +sgml-shorttag:t +sgml-minimize-attributes:nil +sgml-always-quote-attributes:t +sgml-indent-step:2 +sgml-indent-data:t +sgml-parent-document:nil +sgml-default-dtd-file:nil +sgml-exposed-tags:nil +sgml-local-catalogs:nil +sgml-local-ecat-files:nil +End: +--> diff --git a/debian/patches/fix_misspell.patch b/debian/patches/fix_misspell.patch new file mode 100644 index 0000000..8b5a0eb --- /dev/null +++ b/debian/patches/fix_misspell.patch @@ -0,0 +1,29 @@ +Description: Fixed misspelled words in source code. +Author: Lucas de Castro Borges <lucascastroborges@gmail.com> +Last-Update: 2016-07-21 +Index: lsm-1.0.4/lsm.c +=================================================================== +--- lsm-1.0.4.orig/lsm.c ++++ lsm-1.0.4/lsm.c +@@ -134,7 +134,7 @@ int main(int argc, char *argv[]) { + + /* + Create the handler for child signals. This will clean up +- any forked child after an event has occured. ++ any forked child after an event has occurred. + */ + create_sigchld_hdl(); + +Index: lsm-1.0.4/config.c +=================================================================== +--- lsm-1.0.4.orig/config.c ++++ lsm-1.0.4/config.c +@@ -164,7 +164,7 @@ void init_config(void) + + defaults.long_down_email = NULL; + +- /* by default don't execute notify script on unkown to up event */ ++ /* by default don't execute notify script on unknown to up event */ + defaults.unknown_up_notify = 0; + + /* by default no accelerated startup */ diff --git a/debian/patches/hardening_improve.patch b/debian/patches/hardening_improve.patch new file mode 100644 index 0000000..757e64f --- /dev/null +++ b/debian/patches/hardening_improve.patch @@ -0,0 +1,50 @@ +Description: Deleted not needed sets, make already do built-in. +Author: Lucas de Castro Borges <lucascastroborges@gmail.com> +Last-Update: 2016-05-19 +Forwarded: yes +Index: lsm-1.0.4/Makefile +=================================================================== +--- lsm-1.0.4.orig/Makefile ++++ lsm-1.0.4/Makefile +@@ -14,8 +14,6 @@ override CFLAGS += -Wall -O2 -DLSM_VERSI + #override CFLAGS += -D NO_PLUGIN_EXPORT_MUNIN + #override CFLAGS += -D NO_PLUGIN_EXPORT_STATUS + +-LDFLAGS = +- + PREFIX ?= /usr/local + DESTDIR ?= + BINDIR ?= $(PREFIX)/sbin +@@ -34,14 +32,10 @@ override CFLAGS += -DSCRIPTDIR=\"$(SCRIP + + all: $(PROGS) + +-%.o: %.c +- $(CC) $(CFLAGS) -c -o $@ $< +- + lsm: lsm.o icmp_t.o icmp6_t.o config.o globals.o cksum.o forkexec.o signal_handler.o timecalc.o plugin_export.o save_statuses.o pidfile.o cmdline.o usage.o +- $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) + + clean distclean: +- rm -rf *~ .*~ *.o $(PROGS) Makefile.depend debugfiles.list debuglinks.list debugsources.list *.orig ++ rm -rf *~ .*~ *.o $(PROGS) debugfiles.list debuglinks.list debugsources.list *.orig + + tar: distclean + tar zcvf ../$(PKG)-$(VERSION).tar.gz \ +@@ -56,9 +50,6 @@ rpm: tar + cp $(PKG).spec ~/rpmbuild/SPECS + rpmbuild -ba ~/rpmbuild/SPECS/$(PKG).spec + +-Makefile.depend: *.c *.h Makefile +- $(CC) -MM *.c > $@ +- + install: all + install -d $(DESTDIR)$(EXAMPLEDIR) + install -d $(DESTDIR)$(SCRIPTDIR) +@@ -68,6 +59,4 @@ install: all + install -m0644 $(DOCFILES) $(DESTDIR)$(EXAMPLEDIR) + install -m0755 $(SCRIPTS) $(DESTDIR)$(SCRIPTDIR) + +--include Makefile.depend +- + # diff --git a/debian/patches/install_target.patch b/debian/patches/install_target.patch new file mode 100644 index 0000000..38120b1 --- /dev/null +++ b/debian/patches/install_target.patch @@ -0,0 +1,59 @@ +Description: Made target up to PREFIX and pass path to binary at compiling. +Author: Lucas de Castro Borges <lucascastroborges@gmail.com> +Last-Update: 2016-05-09 +Forwarded: yes +Index: lsm-1.0.4/Makefile +=================================================================== +--- lsm-1.0.4.orig/Makefile ++++ lsm-1.0.4/Makefile +@@ -16,12 +16,20 @@ override CFLAGS += -Wall -O2 -DLSM_VERSI + + LDFLAGS = + +-INITDDIR ?= /etc/init.d +-DOCDIR ?= /usr/share/doc/lsm ++PREFIX ?= /usr/local ++DESTDIR ?= ++BINDIR ?= $(PREFIX)/sbin ++ETCDIR ?= /etc/lsm ++DOCDIR ?= $(PREFIX)/share/doc/lsm ++EXAMPLEDIR ?= $(DOCDIR)/examples ++SCRIPTDIR ?= $(PREFIX)/share/lsm + + DOCFILES = README lsm.conf.sample default_script.sample rsyslog-lsm.conf.sample + SCRIPTS = shorewall_script shorewall6_script default_script group_script + ++override CFLAGS += -DETCDIR=\"$(ETCDIR)\" ++override CFLAGS += -DSCRIPTDIR=\"$(SCRIPTDIR)\" ++ + .PHONY: all clean distclean tar rpm + + all: $(PROGS) +@@ -52,20 +60,13 @@ Makefile.depend: *.c *.h Makefile + $(CC) -MM *.c > $@ + + install: all +- mkdir -p $(DESTDIR)/etc/lsm +- mkdir -p $(DESTDIR)$(INITDDIR) +- mkdir -p $(DESTDIR)/usr/sbin +- mkdir -p $(DESTDIR)$(DOCDIR) +- mkdir -p $(DESTDIR)/usr/share/lsm +- mkdir -p $(DESTDIR)/usr/libexec/lsm +- mkdir -p $(DESTDIR)/var/lib/lsm +- install -m0644 lsm.conf $(DESTDIR)/etc/lsm +- install -m0755 lsm.init $(DESTDIR)$(INITDDIR)/lsm +- install -m0755 lsm $(DESTDIR)/usr/sbin +- install -m0644 $(DOCFILES) $(DESTDIR)$(DOCDIR) +- install -m0755 $(SCRIPTS) $(DESTDIR)/usr/libexec/lsm +- ln -sf ../../libexec/lsm/default_script $(DESTDIR)/usr/share/lsm/default_script +- ln -sf ../../libexec/lsm/shorewall_script $(DESTDIR)/usr/share/lsm/shorewall_script ++ install -d $(DESTDIR)$(EXAMPLEDIR) ++ install -d $(DESTDIR)$(SCRIPTDIR) ++ install -d $(DESTDIR)/var/lib/lsm ++ install -D -m0644 lsm.conf $(DESTDIR)$(ETCDIR)/lsm.conf ++ install -D -m0755 lsm $(DESTDIR)$(BINDIR)/lsm ++ install -m0644 $(DOCFILES) $(DESTDIR)$(EXAMPLEDIR) ++ install -m0755 $(SCRIPTS) $(DESTDIR)$(SCRIPTDIR) + + -include Makefile.depend + diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..51c2c8c --- /dev/null +++ b/debian/patches/series @@ -0,0 +1,4 @@ +fix_misspell.patch +source_relative_path.patch +install_target.patch +hardening_improve.patch diff --git a/debian/patches/source_relative_path.patch b/debian/patches/source_relative_path.patch new file mode 100644 index 0000000..27413d2 --- /dev/null +++ b/debian/patches/source_relative_path.patch @@ -0,0 +1,109 @@ +Description: Changed to relative path, informed by compiler at compiling time. +Author: Lucas de Castro Borges <lucascastroborges@gmail.com> +Last-Update: 2016-05-20 +Forwarded: yes +Index: lsm-1.0.4/config.c +=================================================================== +--- lsm-1.0.4.orig/config.c ++++ lsm-1.0.4/config.c +@@ -23,6 +23,8 @@ License: GPLv2 + #include "config.h" + #include "defs.h" + ++#define DEFAULT_SCRIPT_FILE SCRIPTDIR "/default_script" ++ + static CONFIG defaults; + static int errors = 0; + +@@ -144,7 +146,7 @@ void init_config(void) + defaults.name = strdup("defaults"); + defaults.checkip = strdup("127.0.0.1"); + defaults.eventscript = NULL; +- defaults.notifyscript = strdup("/usr/libexec/lsm/default_script"); ++ defaults.notifyscript = strdup(DEFAULT_SCRIPT_FILE); + defaults.max_packet_loss = 15; + defaults.max_successive_pkts_lost = 7; + defaults.min_packet_loss = 5; +Index: lsm-1.0.4/globals.c +=================================================================== +--- lsm-1.0.4.orig/globals.c ++++ lsm-1.0.4/globals.c +@@ -12,13 +12,15 @@ License: GPLv2 + #include "globals.h" + #include "defs.h" + ++#define LSM_CONFIG_FILE ETCDIR "/lsm.conf" ++ + static char *prog = NULL; + static int cont = TRUE; + static int dump = FALSE; + static int ident = 0; + static int reload_cfg = FALSE; + static int dump_if_list = FALSE; +-static char *configfile = "/etc/lsm/lsm.conf"; ++static char *configfile = LSM_CONFIG_FILE; + static char *pidfile = "/var/run/lsm.pid"; + static int nodaemon = 0; + static char *status_str[] = { "down", "up", "unknown", "long_down" }; +Index: lsm-1.0.4/lsm.conf +=================================================================== +--- lsm-1.0.4.orig/lsm.conf ++++ lsm-1.0.4/lsm.conf +@@ -20,7 +20,7 @@ + # name=defaults + # checkip=127.0.0.1 + # eventscript= +-# notifyscript=/usr/libexec/lsm/default_script ++# notifyscript=/usr/share/lsm/default_script + # max_packet_loss=15 + # max_successive_pkts_lost=7 + # min_packet_loss=5 +Index: lsm-1.0.4/lsm.conf.sample +=================================================================== +--- lsm-1.0.4.orig/lsm.conf.sample ++++ lsm-1.0.4/lsm.conf.sample +@@ -18,7 +18,7 @@ debug=8 + defaults { + name=defaults + checkip=127.0.0.1 +- eventscript=/usr/libexec/lsm/default_script ++ eventscript=/usr/share/lsm/default_script + max_packet_loss=15 + max_successive_pkts_lost=7 + min_packet_loss=5 +@@ -45,7 +45,7 @@ defaults { + # connection { + # name=connection-1 + # checkip=127.108.68.69 +-# eventscript=/usr/libexec/lsm/conn1 ++# eventscript=/usr/share/lsm/conn1 + # max_packet_loss=15 + # max_successive_pkts_lost=7 + # min_packet_loss=5 +@@ -62,7 +62,7 @@ defaults { + # connection { + # name=connection-2 + # checkip=127.108.68.65 +-# eventscript=/usr/libexec/lsm/conn2 ++# eventscript=/usr/share/lsm/conn2 + # max_packet_loss=15 + # max_successive_pkts_lost=7 + # min_packet_loss=5 +@@ -79,7 +79,7 @@ defaults { + # connection { + # name=connection-3 + # checkip=127.108.68.68 +-# eventscript=/usr/libexec/lsm/conn3 ++# eventscript=/usr/share/lsm/conn3 + # max_packet_loss=15 + # max_successive_pkts_lost=7 + # min_packet_loss=5 +@@ -131,7 +131,7 @@ defaults { + # + # group { + # name=conn-group-a +-# eventscript=/usr/libexec/lsm/default_script ++# eventscript=/usr/share/lsm/default_script + # warn_email=root@some.domain.tld + # # logic between member connetion statuses + # # logic=0 == or diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..9fa378a --- /dev/null +++ b/debian/rules @@ -0,0 +1,21 @@ +#!/usr/bin/make -f +# see FEATURE AREAS in dpkg-buildflags(1) +export DEB_BUILD_MAINT_OPTIONS = hardening=+all + +#DEBUG=true + +%: + dh $@ + +override_dh_auto_build: + docbook-to-man debian/lsm.sgml > debian/lsm.1 + dh_auto_build -- PREFIX=/usr + +override_dh_installchangelogs: + dh_installchangelogs debian/upstream/changelog + +override_dh_auto_install: + dh_auto_install -- PREFIX=/usr + +override_dh_installinit: + dh_installinit --no-start diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/upstream/changelog b/debian/upstream/changelog new file mode 100644 index 0000000..38fc90b --- /dev/null +++ b/debian/upstream/changelog @@ -0,0 +1,751 @@ +* Tue Jan 26 2016 Mika Ilmaranta <ilmis@nullnet.fi> - 1.0.4-1 +- For systemd start after shorewall otherwise shorewall_script + may be executed too early + +* Fri Dec 4 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 1.0.3-1 +- recursive read_config reported errors many times + +* Fri Dec 4 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 1.0.2-1 +- call init_config in reload_config + +* Fri Dec 4 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 1.0.1-1 +- double free() fix? + +* Thu Nov 19 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 1.0-1 +- script API change. pass empty strings to scripts without converting to + "-" or "NA". +- include and -include now support patterns + +* Tue Nov 17 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.195-1 +- fix dynamic memory handling in sane values in code. + +* Mon Nov 16 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.194-1 +- set sane values in code. overridable in config defaults section as + before. + +* Sat Oct 31 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.193-1 +- use full path for -included file + +* Fri Oct 30 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.192-1 +- default_script: run date after checks + +* Fri Oct 30 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.191-1 +- support for -include aka ignore include errors if file is missing + +* Fri Oct 23 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.190-1 +- fix groups_decide logic when group logic is 'or'. Thanks to + Filippo Carletti for noticing there was a problem. + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.189-1 +- update stats must not clear target used count + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.188-1 +- moved target used slots book keeping to send function + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.187-1 +- update stats after each ping round so that startup burst can use used slot + count + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.186-1 +- dump startup acceleration and startup burst config also +- startup acceleration logic fix + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.185-1 +- startup burst logic rewrite + +* Mon Jun 1 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.184-1 +- two separate config params for startup burst + +* Sun May 31 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.183-1 +- startup acceleration configurable +- startup burst configurable + +* Sun May 31 2015 Tuomo Soini <tis@foobar.fi> - 0.182-1 +- add shorewall6_script and group_script +- install scripts to /usr/libexec/lsm +- add compatibility symlinks to /usr/share/lsm + +* Fri May 29 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.181-1 +- accelerate decision at startup, must have received at least one packet + +* Fri May 29 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.180-1 +- accelerate decision at startup + +* Tue Feb 3 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.179-1 +- lsm.service use correct path for the binary + +* Wed Jan 14 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.178-1 +- export status info to separate file +- cleaned up compilation with different sets of NO_PLUGIN_EXPORT defines + +* Mon Jan 12 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.177-1 +- export connection statuses to plugin directory + +* Sun Jan 11 2015 Mika Ilmaranta <ilmis@nullnet.fi> - 0.176-1 +- log status with other attributes (Luigi Iotti) + +* Sat Sep 13 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.175-1 +- if --no-fork don't write pid file + +* Sat Sep 13 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.174-1 +- systemd support + +* Wed Aug 6 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.173-1 +- fixed -v parameter + +* Wed Aug 6 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.172-1 +- better usage help +- fixed bug in optarg use + +* Wed Aug 6 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.171-1 +- split source for pidfile processing +- real cmdline argument processing with optarg +- support no-daemon cmdline option for integration with systemd +- debug level 100 no longer suppresses daemonization use the above + mentioned cmdline option instead + +* Sun Feb 16 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.170-1 +- Makefile: debian frendlier install target + +* Sun Feb 16 2014 Mika Ilmaranta <ilmis@nullnet.fi> - 0.169-1 +- Makefile: install target, not guaranteed to work +- README: updated with INSTALL section + +* Fri Nov 22 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.168-1 +- zero timeout_max and consecutive_missing_max in dump_statuses if there is + status_change to up state not in decide + +* Fri Nov 22 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.167-1 +- update timeout_max and consecutive_missing_max regardless of state + +* Fri Nov 22 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.166-1 +- added timeout_max + +* Fri Nov 22 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.165-1 +- drop max_successive_waiting, it delivers no additional info +- renamed max_successive_missing to successive_missing_max + +* Fri Nov 22 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.164-1 +- added max_successive_waiting and max_successive_missing +- cfg.debug controls now how much info is syslogged on dump_status + debug >= 6, log calculated connection status + debug >= 7, log connection probe statuses + +* Fri Aug 9 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.163-1 +- don't suppress all up notifies when unknown_up_notify is off + +* Thu Jul 25 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.162-1 +- option to skip executing notify script on unknown to up event for groups + also + +* Thu Jul 25 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.161-1 +- added option to skip executing notify script on unknown to up event + +* Thu Jul 25 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.160-1 +- moved save/restore statuses to their own file from lsm.c + +* Wed Jul 24 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.159-1 +- updated shorewall_script with new parameters + +* Wed Jul 24 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.158-1 +- clean up munin titles + +* Tue Jul 23 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.157-1 +- use connection names in munin labels + +* Fri Jul 19 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.156-1 +- plugin_export: changed strlower to munin_src_name + +* Thu Jul 18 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.155-1 +- plugin_export: export statistics for munin + +* Wed Jul 17 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.154-1 +- fixed divide error + +* Wed Jul 17 2013 Mika Ilamranta <ilmis@nullnet.fi> - 0.153-1 +- lsm.c: drop casts and keep avg_rtt in usec, divide by 1000.0 if needed as + float + +* Wed Jul 17 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.152-1 +- lsm.c: cast avg_rtt for fork_exec + +* Wed Jul 17 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.151-1 +- prepare for exporting statistics to zabbix and munin + +* Wed Jul 10 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.150-1 +- lsm.c: change status to up directly from long_down + +* Tue Jul 9 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.149-1 +- default_script: added missing closing curly bracket + +* Mon Jul 8 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.148-1 +- pass event timestamp from lsm to scripts + +* Mon Jul 8 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.147-1 +- pass empty warn_email addr to script as hyphen +- if script gets hyphen for email addr do not send mail + +* Thu Jul 4 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.146-1 +- long_down_to down -> long_down_to_down + +* Thu Jul 4 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.145-1 +- check also for nul-string email addr + +* Mon Jul 1 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.144-1 +- use enum for status +- new config options for reporting only longer down time: +- long_down_time = how many seconds down time is considered long +- long_down_email = where to report long down time +- long_down_notifyscript = script to use when reporting long down time +- long_down_eventscript = script to use when reacting to long down time + +* Fri May 10 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.143-1 +- discard probed src addr if bind fails + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.142-1 +- free exec_queue on exit + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.141-1 +- make exec_queue_dump activate with -DDEBUG +- rsyslog-lsm.conf.sample by Dimitar Angelov + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.140-1 +- debug with exec_queue_dump + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.139-1 +- forkexec.c: check that eq is set in exec_queue_process + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.138-1 +- config.c: defaults.queue NULL + +* Thu Mar 28 2013 Mika Ilmaranta <ilmis@nullnet.fi> - 0.137-1 +- exec queue, run event scripts sychronously + +* Thu Oct 11 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.136-1 +- lsm.c: clean up debugging and add check that reply addr matches + original destination addr + +* Thu Oct 11 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.135-1 +- lsm.c: more debugging when pdp->id is out of range + +* Thu Oct 11 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.134-1 +- lsm.c: do bounds check on pdp->id before use as ctable index + +* Mon Aug 13 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.133-1 +- lsm.c: rethought group up/down logic. (original was wrong up event on + transition to unknown state and 0.132 fix reported both up and down + events) + +* Mon Aug 13 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.132-1 +- default_script: better english for timeout packets +- config.c: recognise status for group, use default start status for group +- lsm.c: report group prevstate textually + +* Sat May 12 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.131-1 +- close socket on recvfrom fail + +* Tue May 8 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.130-1 +- initialize cmsgbuf and cmsglen in open_icmp_sock as socket may be + closed and reopened + +* Sun May 6 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.129-1 +- close socket also when sendmsg fails + +* Sun May 6 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.128-1 +- cleanup debugging +- don't SO_BINDTODEVICE for AF_INET6 when device is specified as it uses + sendmsg instead of sendto + +* Sun May 6 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.127-1 +- debug sendmsg a little + +* Sun May 6 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.126-1 +- set v6 filter + +* Sun May 6 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.125-1 +- handle v6 device setting like ping6 does + +* Sat May 5 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.124-1 +- v6 sequence now correct? +- set v6 sockopts also if ttl is not set + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.123-1 +- removed unnesessary debugging +- v6 src ip addr autodiscovery works now + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.122-1 +- debug memcpy t->src6 results + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.121-1 +- check t->src6 contents + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.120-1 +- debug v6 getsockname unconditionally + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.119-1 +- debug getsockname for v6 conn + +* Thu Apr 19 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.118-1 +- no SO_DONTROUTE for v6 probe + +* Fri Apr 13 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.117-1 +- lsm.c: set more v6 socket options +- TODO: check why probe_src_ip_addr doesn't work for v6 + +* Sat Mar 10 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.116-2 +- fix forkexec format str + +* Sat Mar 10 2012 Mika Ilmaranta <ilmis@nullnet.fi> - 0.116-1 +- report prevstate as string up/down/unknown + +* Wed Mar 7 2012 Tuomo Soini <tis@foobar.fi> - 0.115-2 +- fix %%postun not to fail + +* Wed Dec 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.115-1 +- forkexec.c: remove space after func name +- lsm.c: free_config_data: don't close t->sock if it is -1 + +* Wed Dec 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.114-1 +- moved time calculation functions to their own files + +* Wed Dec 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.113-1 +- decode all icmp and icmp6 types and codes + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.112-1 +- Andrew Beverley's signal child handler +- made static functions static + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.111-1 +- moved children handling from forkexec to main loop + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.110-1 +- lsm.c: use t->dst6 in v6 probe not cur->dstinfo + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.109-1 +- rebuild with efence + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.108-1 +- ipv6 support seems now stable enough + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.107-1 +- lsm.c: debug probe_src_ip_addr call + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.106-1 +- lsm.c: debug open_icmp_sock socket call removed +- lsm.c: debug setting v6 src addr + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.105-1 +- lsm.c: debug open_icmp_sock socket call + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.104-1 +- lsm.c: more sin6_family fixes + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.103-1 +- lsm.c: set sin6_family and show also v4 addr in debug + +* Tue Dec 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.102-1 +- lsm.c: debug reply pkts more + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.101-1 +- lsm.c: fix inet_pton parameters + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.100-1 +- lsm.c: fail if device can not be bound to by Andrew Beverley +- lsm.c: bind also to ipv6 sourceip + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.99-1 +- lsm.c: fix ping6 sendto params + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.98-1 +- initial ipv6 support + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.97-1 +- include version information in directory name inside tar pkg + +* Mon Dec 19 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.96-1 +- lsm.c: initialize last decision outside main loop. fixes decide call + interval. patch by Andrew Beverley +- config.c: debugging information added for unmatched config option by + Andrew Beverley. strcpy changed to memmove in strip leading space +- lsm.c: show correct usage +- config.c: clean up config file lines harder before parsing + +* Fri Dec 9 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.95-1 +- shorewall_script: removed email notification, use it as eventscript and + default_script as notifyscript for example + +* Fri Dec 9 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.94-1 +- added support for worker script (= eventscript) and notify script + (= notifyscript) differentiation, both are called with same parameters. + new script parameter previous state + +* Thu Dec 8 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.93-1 +- for the following two patches thanks to Pablo Gomez +- lsm.c: use sourceip from config for icmp pkts if set +- lsm.c,config.c: new default state is unknown, which can be overridden in + config. this allows lsm to run event script "on startup" after connection + statuses are discovered. same rules apply as for actual events. + +* Thu Oct 20 2011 Mika Ilmaranta <ilmis@nullnet.fi>> - 0.92-1 +- report same seq status only once + +* Thu Oct 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.91-1 +- dump conn status to syslog every maxseq when status is down only + if no status change + +* Thu Oct 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.90-1 +- dump conn status to syslog every maxseq when status is down + +* Tue Sep 27 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.89-1 +- added comment to shrewall_script about shorewall version requirement + +* Tue Sep 27 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.88-1 +- added shorewall_script + +* Fri Jul 15 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.87-1 +- production setting for compilation (no efence and use optimization) + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.86-1 +- protect FD_ISSET also from closed socket + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.85-1 +- compile with ElectricFence + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.84-1 +- revert to v0.64 base +- Makefile: merge v0.83 changeset +- lsm.spec: v0.83 spec +- config: removed reopen_on_enodev and added patch for double free +- lsm.c: removed reopen_on_enodev handling +- lsm.conf: removed reopen_on_enodev +- added cksum files +- lsm.c: use external cksum +- v0.83 forkexec, globals and signal_handler +- lsm.c: separate defs.h, merged fixes from v0.83 +- lsm.c: close socket on fail and reopen just before next ping +- spec: version and changelog + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.83-1 +- check that device names match + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.82-1 +- compile with ElectricFence depending on devel define + +* Wed Jun 22 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.81-1 +- check arp header differently + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.80-1 +- further debugging of disappearing arp replies + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.79-1 +- try to find out where arp replies vanish + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.78-1 +- config.c: fix double free on warn_email and other group parameters + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.77-1 +- fix BuildRequires for -lefence + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.76-1 +- compile with -lefence + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.75-1 +- check packet from addr to determine which connection it + belongs to + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.74-1 +- moved rest of io functions to io.c +- io.c: split icmp and arp reply handling +- io.c: differentiate ping_rcv error logging on find_interface use + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.73-1 +- bind SIGUSR2 to signal_handler + +* Tue Jun 21 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.72-1 +- dump interface list on SIGUSR2 + +* Mon Jun 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.71-1 +- io.c: due to function splitting add missing gettimeofday call in icmp_send + +* Mon Jun 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.70-1 +- timeval_diff_[lt,gt] fix diff_usec calculation + +* Mon Jun 20 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.69-1 +- removed sock from target structure +- added interface handling to interface.c and made other parts use it + +* Fri Jun 17 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.68-1 +- broke timeval_diff_cmp to two functions +- globals.c: check for unset prog +- lsm.c: removed handle_odd_icmp function as it did nothing +- interface.c: made probe for src ip address function probe_addresses + +* Fri Jun 17 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.67-1 +- moved global variable handling to its own block +- moved decision functions to their own block +- moved signal_handler to its own block +- moved ping function to its own file +- lsm.c: reset reload_cfg after reloading config, not before +- Makefile: clean also ~ files starting with dot + +* Fri Jun 17 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.66-1 +- moved structure definitions to lsm.h +- lsm.c: moved socket opening functionality to interface.c +- Makefile: use Makefile.depend +- .gitignore: ignore Makefile.depend, obj files and lsm binary + +* Wed Jun 15 2011 Mika Ilmaranta <ilmis@nullnet.fi> - 0.65-1 +- started rewrite +- moved forkexec function and defines to their own files +- added interface handling src files +- moved cksum function to its own file +- moved timeval functions to their own files + +* Fri Dec 31 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.64-1 +- fill up target struct src address for ping also + do it at startup (should this be done every time we send ping packet?) + +* Fri Dec 31 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.63-1 +- Added src ip to script parameters + src ip paramater is the last one so that every single old config + doesn't have to be rewritten. + +* Fri Dec 10 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.62-1 +- check for valid ip-address in checkip parameter + +* Fri Dec 10 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.61-1 +- changed lsm.c init_config to init_config_data +- added init_config to config.c which is then called before read_config +- added a warning when checkip is not set + +* Sat Oct 9 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.60-1 +- fix recursive read_config use. set default values only once. +- use cfg.debug only after config is read +- added default_script.sample + +* Mon Sep 27 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.59-1 +- remember connection statuses after config reload + +* Mon Sep 27 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.58-1 +- reopen_on_enodev support. set this to 1 so lsm will try to reopen ping + device when it encounters ENODEV error when sending ping packet + +* Sun Sep 19 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.57-1 +- added defaults status to give initial assumption of the connection status +- added config status for connections. is it assumed down = 0 or up = 1 + at lsm start + +* Sat Sep 18 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.56-1 +- fixed rpmlint-v0.91 warnings. + +* Sat Apr 24 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.53-1 +- added error checking to ftruncate and write so that mock build doesn't + complain +- introduced timeval_diff_cmp function as it seems quite problematic to + really compare times in usec since epoch using integer values. + especially 32bit systems were seeing 99% CPU loads because of this. + +* Thu Apr 22 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.52-1 +- initialize all struct timeval structures to tv_sec = 0 and tv_usec = 0 +- added use of error flag to arping sending + +* Fri Mar 5 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.51-1 +- fix avg rtt calculation comment +- show in the default mail template avg rtt unit [usec] +- in syslog avg rtt is reported in [msec] as of v0.50 like ping does + +* Fri Mar 5 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.50-1 +- report rtt with three decimals accuracy + +* Thu Mar 4 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.49-1 +- count average rtt in milliseconds not in microseconds + +* Thu Mar 4 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.48-1 +- don't count timeouted late replies in cons rcvd + +* Thu Mar 4 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.47-1 +- added some missing fields to lsm.init + +* Thu Mar 4 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.46-1 +- dump all statuses only if requested by SIGUSR1 +- otherwise dump only connection status data of connection whose status changed + +* Wed Mar 3 2010 Mika Ilmaranta <ilmis@nullnet.fi> - 0.45-1 +- use LOG_PID openlog option + +* Thu Dec 17 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.44-1 +- added some parameter sanity checking. if max_packet_loss <= min_packet_loss then there can be a flip-flop effect + and many many and still a few reports mailed to warn_email address. + +* Mon Nov 9 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.43-1 +- convert all tabs to spaces before processing config line + +* Sun Sep 27 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.42-1 +- changed action script to event script to follow suite with config + +* Sun Sep 27 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.41-1 +- added action_script_check() to check for valid action script + +* Wed Sep 2 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.40-1 +- lseek to start of pid file and ftruncate it to zero size before writing + our new pid. this prevents us having two pids in the file if previous + lsm crashed or exited and did not remove the file (fcntl lock is cleared + by kernel as process dies "prematurely"). + +* Mon Jun 29 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.39-1 +- set close on exec flag for fds and sockets +- call closelog() within forked child before exec + +* Thu Jun 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.38-1 +- require mailx for /bin/mail as default_script uses it + +* Thu Jun 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.37-1 +- when dumping config log also group's warn_email and logic +- set last previous last group members next to the new last member + +* Thu Jun 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.36-1 +- apply sane defaults to group parameters + +* Thu Jun 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.35-1 +- only log sendto errors with debug >= 9 + +* Thu Jun 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.34-1 +- better sendto error ignore fix +- changed syslog calls for Mandrake + +* Thu Jun 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.33-1 +- ping_send: don't care about sendto errors + +* Wed Apr 29 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.32-1 +- split long debug explanation line in lsm.conf + +* Wed Apr 29 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.31-1 +- left only defaults in lsm.conf and moved examples to + lsm.conf.sample + +* Tue Apr 28 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.30-1 +- timeval_diff calculation order change to prevent + long overflow. nobody has encoutered that but just to be + sure +- use default ttl=0 which uses system default ttl + +* Sat Apr 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.29-1 +- Added decision making section to README written by Dean Takemori + he suggested to include it in lsm.conf but I thought it was + long enough already + +* Sat Apr 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.28-1 +- Tom Eastep's fix for last_sent_time initialization +- added time stamp to default_script mail body + +* Fri Apr 10 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.27-1 +- added checks for missing group members + +* Fri Apr 10 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.26-1 +- added connection grouping + +* Thu Apr 9 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.25-1 +- gettimeofday failure patch from Dean Takemori + +* Sun Apr 5 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.24-1 +- add support for SIGHUP to reload config + +* Tue Mar 24 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.23-1 +- changed ping packets to use own socket for each target. + looks like setsockopt SO_BINDTOINTERFACE is not reversible and + according to documentation I found using it multiple times + may lead to unpredicted results due to kernel caching. + +* Tue Mar 24 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.22-1 +- changed indentation to tabs + +* Mon Mar 16 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.21-1 +- added LSM: to default_script mail subject + +* Tue Mar 10 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.20-1 +- handle ENODEV as if the ping packet was sent, but do barf to syslog + about it. this will eventually cause a down event. added + an error flag which is set if sendto returns with value < 0. +- dump connection statuses to syslog when up/down-event happens. +- moved status dump's "header" -line above the pkt status bits. +- added error flag dumping. + +* Fri Mar 6 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.19-1 +- fix pid file write order + +* Thu Mar 5 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.18-1 +- added pid file handling + +* Thu Mar 5 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.17-1 +- rebuild because of mystical i386 build problems + +* Wed Mar 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.16-1 +- pass only LANG, PATH and TERM environment variables to + scripts + +* Wed Mar 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.15-1 +- fixed all rpmlint errors reported in binary pkg + which means that default_script is moved to /usr/share/lsm + +* Wed Mar 4 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.14-1 +- added ipv6 support to TODO list +- fixed rpmlint errors in lsm.spec + +* Tue Feb 24 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.13-1 +- typos: lisence -> license +- mention SIGUSR1 behaviour in README +- added a check for ENODEV for ping packets + +* Fri Feb 20 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.12-1 +- don't define device= in defaults + +* Wed Feb 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.11-1 +- if device is not specified return NA + +* Wed Feb 18 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.10-1 +- added device to script parameters +- first try on binding ping packets to device + +* Thu Feb 12 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.9-1 +- fixed rtt comments in default_script + +* Thu Feb 12 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.8-1 +- init script reload fix + +* Sat Feb 7 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.7-1 +- fixed typos +- init script reload was missing + +* Sun Feb 1 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.6-1 +- fixed comments and readme to correspond current status + +* Sun Feb 1 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.6-1 +- now each target has its own ttl setting + +* Sat Jan 31 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-8 +- check for no targets specified in conf + +* Sat Jan 31 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-7 +- all except DEBUG is now syslogged + +* Sat Jan 31 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-4 +- added ttl setting handling for ping packets. currently all + ping monitored links share a common ttl value which is + taken from the first config entry's ttl value. +- when SIGUSR1 is received lsm dumps current packet info to + syslog ... + +* Sat Jan 31 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-3 +- changed avg rtt calculation so that only replied packets' + rtt is counted + +* Sat Jan 31 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-2 +- Added a ping reply packet min size check + +* Fri Jan 30 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.5-1 +- started adding support for arp check which is actually + using arp packets rather than ping packets in case + your gw administrators have blocked ping + +* Thu Jan 29 2009 Mika Ilmaranta <ilmis@nullnet.fi> - 0.4-1 +- Initial build diff --git a/debian/watch b/debian/watch new file mode 100644 index 0000000..ff65485 --- /dev/null +++ b/debian/watch @@ -0,0 +1,2 @@ +version=4 +http://lsm.foobar.fi/download/lsm-(.*)\.tar\.gz |
