--- jabberd2-2.2.8.orig/debian/compat +++ jabberd2-2.2.8/debian/compat @@ -0,0 +1 @@ +7 --- jabberd2-2.2.8.orig/debian/postinst +++ jabberd2-2.2.8/debian/postinst @@ -0,0 +1,28 @@ +#!/bin/sh + +set -e + +case "$1" in + configure) + chown jabber:jabber /etc/jabberd2 + chmod 750 /etc/jabberd2 + chown jabber:jabber /var/lib/jabberd2 + chmod 750 /var/lib/jabberd2 + chown jabber:jabber /var/log/jabberd2 + chmod 750 /var/log/jabberd2 + chown jabber:jabber /var/run/jabberd2 + chmod 755 /var/run/jabberd2 + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 --- jabberd2-2.2.8.orig/debian/postrm +++ jabberd2-2.2.8/debian/postrm @@ -0,0 +1,37 @@ +#!/bin/sh + +set -e + +case "$1" in + purge) + # remove the user database + rm -f /var/lib/jabberd2/db/* + rm -f /var/lib/jabberd2/*.db + for SUB in c2s s2s sm router resolver; do + # the application should remove these on exit + rm -f /var/run/jabberd2/${SUB}.pid + # need better way of detecting whether these exist or not + rm -f /var/log/jabberd2/${SUB}.log* + done + # remove any empty directories + for DIR in /etc/jabberd2/component.d /var/lib/jabberd2/db \ + /var/lib/jabberd2 /etc/jabberd2 \ + /var/run/jabberd2 /var/log/jabberd2; do + if [ -d ${DIR} ]; then + #rmdir -p --ignore-fail-on-non-empty ${DIR} > /dev/null 2>&1 + rmdir --ignore-fail-on-non-empty ${DIR} > /dev/null 2>&1 + fi + done + ;; + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 --- jabberd2-2.2.8.orig/debian/default +++ jabberd2-2.2.8/debian/default @@ -0,0 +1,20 @@ +# /etc/default/jabberd2 - default values for jabberd2 + +# user and group +USER=jabber +GROUP=jabber + +# run router +ROUTER_RUN=1 + +# run resolver +RESOLVER_RUN=1 + +# run sm +SM_RUN=1 + +# run s2s +S2S_RUN=1 + +# run c2s +C2S_RUN=1 --- jabberd2-2.2.8.orig/debian/docs +++ jabberd2-2.2.8/debian/docs @@ -0,0 +1,5 @@ +NEWS +README +README.protocol +TODO +UPGRADE --- jabberd2-2.2.8.orig/debian/preinst +++ jabberd2-2.2.8/debian/preinst @@ -0,0 +1,53 @@ +#!/bin/sh + +set -e + +# remove a no-longer used conffile +rm_conffile() { + local PKGNAME="$1" + local CONFFILE="$2" + + [ -e "$CONFFILE" ] || return 0 + + local md5sum="$(md5sum $CONFFILE | sed -e 's/ .*//')" + local old_md5sum="$(dpkg-query -W -f='${Conffiles}' $PKGNAME | \ + sed -n -e "\' $CONFFILE ' { s/ obsolete$//; s/.* //; p }")" + if [ "$md5sum" != "$old_md5sum" ]; then + echo "Obsolete conffile $CONFFILE has been modified by you." + echo "Saving as $CONFFILE.dpkg-bak ..." + mv -f "$CONFFILE" "$CONFFILE".dpkg-bak + else + echo "Removing obsolete conffile $CONFFILE ..." + rm -f "$CONFFILE" + fi +} + +case "$1" in + install|upgrade) + rm_conffile jabberd2 "/etc/jabberd2/resolver.xml" + rm_conffile jabberd2 "/etc/jabberd2/component.d/20resolver" + ;; + + abort-upgrade) + ;; + + *) + echo "preinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +if ! getent group | grep -q "^jabber:" +then + addgroup --system jabber +fi + +if ! getent passwd | grep -q "^jabber:" +then + adduser --system --home /var/lib/jabberd2 --no-create-home \ + --quiet --disabled-password --ingroup jabber jabber +fi + +#DEBHELPER# + +exit 0 --- jabberd2-2.2.8.orig/debian/watch +++ jabberd2-2.2.8/debian/watch @@ -0,0 +1,2 @@ +version=3 +ftp://ftp.xiaoka.com/jabberd2/releases/jabberd-(.*)\.tar\.gz --- jabberd2-2.2.8.orig/debian/dirs +++ jabberd2-2.2.8/debian/dirs @@ -0,0 +1,6 @@ +etc/jabberd2/component.d +etc/jabberd2/sm.d +usr/sbin +var/log/jabberd2 +var/run/jabberd2 +var/lib/jabberd2 --- jabberd2-2.2.8.orig/debian/init +++ jabberd2-2.2.8/debian/init @@ -0,0 +1,59 @@ +#!/bin/sh +### BEGIN INIT INFO +# Provides: jabberd2 +# Required-Start: $network $named $remote_fs +# Required-Stop: $network $named $remote_fs +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: jabberd2 init script to start jabberd2 daemon +### END INIT INFO + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +COMPONENTDPATH=/etc/jabberd2/component.d +PIDPATH=/var/run/jabberd2 + +test -d ${COMPONENTDPATH} || exit 0 + +if [ ! -d ${PIDPATH} ]; then + mkdir -p ${PIDPATH} + chown ${USER}:${GROUP} ${PIDPATH} +fi + +case "$1" in + start) + echo -n "Starting Jabber services:" + if [ -z "$2" ]; then + run-parts --arg=start ${COMPONENTDPATH} + else + ${COMPONENTDPATH}/??$2 start + fi + echo "." + ;; + stop) + echo -n "Stopping Jabber services:" + if [ -z "$2" ]; then + run-parts --reverse --arg=stop ${COMPONENTDPATH} + else + ${COMPONENTDPATH}/??$2 stop + fi + echo "." + ;; + restart|force-reload) + echo "Restarting Jabber services:" + $0 stop $2 + sleep 1 + $0 start $2 + ;; + *) + # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 + echo "Usage: $0 {action} [component]" >&2 + echo " action = start|stop|restart|force-reload" >&2 + echo " component = router|resolver|sm|s2s|c2s" >&2 + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/control +++ jabberd2-2.2.8/debian/control @@ -0,0 +1,22 @@ +Source: jabberd2 +Section: net +Priority: optional +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Debian XMPP Maintainers +Uploaders: Jorge Salamero Sanz , Thadeu Lima de Souza Cascardo +Build-Depends: debhelper (>= 7), dpatch, autotools-dev, automake, libtool, libssl-dev, libgsasl7-dev (>= 0.2.27), libdb-dev, libpam0g-dev, libmysqlclient15-dev, libpq-dev, libldap2-dev, libsqlite3-dev, libidn11-dev, libexpat1-dev, libudns-dev +Standards-Version: 3.8.1 +Homepage: http://jabberd2.xiaoka.com/ + +Package: jabberd2 +Architecture: any +Conflicts: jabberd2-bdb, jabberd2-mysql, jabberd2-pgsql, jabberd2-ldap-bdb, jabberd2-ldap-mysql, jabberd2-ldap-pgsql +Replaces: jabberd2-bdb, jabberd2-mysql, jabberd2-pgsql, jabberd2-ldap-bdb, jabberd2-ldap-mysql, jabberd2-ldap-pgsql +Depends: adduser, ${shlibs:Depends} +Description: Jabber instant messenger server + Jabber is a free instant messaging server based on XMPP. + . + This package contains Jabberd 2, the next generation of the Jabberd + server. It has been rewritten from the ground up to be scalable, + architecturally sound, and to support the latest protocol extensions + coming out of the XSF. --- jabberd2-2.2.8.orig/debian/logrotate +++ jabberd2-2.2.8/debian/logrotate @@ -0,0 +1,8 @@ +/var/log/jabberd2/*.log { + weekly + missingok + rotate 10 + copytruncate + delaycompress + compress +} --- jabberd2-2.2.8.orig/debian/changelog +++ jabberd2-2.2.8/debian/changelog @@ -0,0 +1,201 @@ +jabberd2 (2.2.8-2.2ubuntu1) quantal; urgency=low + + * SECURITY UPDATE: Fixed possibility of Unsolicited Dialback Attacks + - debian/patches/CVE-2012-3525.dpatch: check Verify Response and + Authorization Response in s2s sessions + - CVE-2012-3525 + + -- Jamie Strandboge Thu, 23 Aug 2012 08:07:18 -0500 + +jabberd2 (2.2.8-2.2build1) precise; urgency=low + + * Rebuild for libmysqlclient transition + + -- Clint Byrum Wed, 23 Nov 2011 23:36:51 -0800 + +jabberd2 (2.2.8-2.2) unstable; urgency=low + + * Non-maintainer upload. + * Don't ship .la files (Closes: #621606). + + -- Luk Claes Wed, 22 Jun 2011 08:14:00 +0200 + +jabberd2 (2.2.8-2.1) unstable; urgency=high + + * Non-maintainer upload by the Security Team. + * Prevent entity expansion in order to prevent about + the billion laughs DoS attack (CVE-2011-1755.dpatch). + + -- Nico Golde Mon, 30 May 2011 23:40:50 +0200 + +jabberd2 (2.2.8-2) unstable; urgency=low + + * Deletes resolver configuration files (Closes: #528105). + + -- Jorge Salamero Sanz Sun, 24 May 2009 01:21:47 +0100 + +jabberd2 (2.2.8-1) unstable; urgency=low + + * New Upstream Version (Closes: #525417). + * Added a implicit-pointer-conversion patch (Closes: #525878). + * Added Thadeu Lima de Souza Cascardo as Uploader. + * Build-Depends on libgsasl7-dev >= 0.2.27 (Closes: #525239). + + -- Jorge Salamero Sanz Fri, 01 May 2009 14:39:42 +0100 + +jabberd2 (2.2.7.1-2) unstable; urgency=low + + * Added missing build dependency on libudns-dev (Closes: #524581). + + -- Jorge Salamero Sanz Sat, 18 Apr 2009 12:35:54 +0100 + +jabberd2 (2.2.7.1-1) unstable; urgency=low + + * New upstream release (Closes: #494628). + * New maintainer Debian XMPP Maintainers. + * Changed build-dep to libdb-dev (Closes: #515859). + * Bumped to debhelper 7 and Standards-Version. + * Merged Ubuntu fix for the pidpath creation and chown. + * rules: Added libtoolize call (jabberd2 ships with an older ltmain.sh + version that conflicts with the current libtool version). + + -- Jorge Salamero Sanz Fri, 17 Apr 2009 16:39:07 +0100 + +jabberd2 (2.1.24.1-1) unstable; urgency=low + + * New upstream release (Closes: #403750). + + photo support in mod_iq_vcard included (Closes: #311170). + + c2s no longer crashes when speaking ssl to the tls port + (Closes: #245306). + * Packaging is completly new almost from scratch: + * Multiple binaries packages merged into a single binary with support for + all databases and auth methods + (Closes: #386900, #414152, #406459, #357733, #386653, #406460). + * compat: updated to version 5. + * control: no longer depends on jabber-common (Closes: #324829). + * control: updated to libpq-dev (Closes: #409765). + * control: built against libgsasl (Closes: #402498). + * control: Homepage field. + * copyright: completly new file. + * default, [pre|post]scripts: daemons run as jabber:jabber + (Closes: #440302). + * dirs, docs: updated with minor changes. + * init: updated to use LSB headers. + * lintian-overrides: jabberd2 is licensed with the openssl exception. + * logrotate: logs are rotated (Closes: #345212). + * watch: new watch file with the new upstream authors. + * patches: + + change PKGNAME from jabberd to jabberd2. + + change defaults paths to LSB compatible. + + -- Jorge Salamero Sanz Fri, 04 Apr 2008 09:59:47 +0000 + +jabberd2 (2.0s11-1) experimental; urgency=low + + * New upstream release (closes: #357874). + * Add myself to the uploaders list. + * Ack NMU (thanks Clément). + + -- Andres Salomon Fri, 16 Jun 2006 01:58:46 +0000 + +jabberd2 (2.0s10-1.1) experimental; urgency=high + + * Non-maintainer upload + * Fix mysql library dependency (Closes:#358642) + + -- Clément Stenac Sat, 10 Jun 2006 14:00:00 +0200 + +jabberd2 (2.0s10-1) experimental; urgency=low + + * new upstream version + + -- Jamin W. Collins Fri, 7 Oct 2005 09:47:16 -0600 + +jabberd2 (2.0s9-1) experimental; urgency=low + + * new upstream release (Closes: #305024) + + -- Jamin W. Collins Fri, 19 Aug 2005 08:44:10 -0600 + +jabberd2 (2.0s8-1) experimental; urgency=low + + * new upstream release (Closes: #305024) + * SSL connections to non-SSL ports no longer crash c2s (Closes: #245306) + - not sure at what point this was corrected, but current testing + shows that it no longer appears to be a problem. + + -- Jamin W. Collins Thu, 21 Apr 2005 13:07:15 -0600 + +jabberd2 (2.0s6-1) experimental; urgency=low + + * new upstream release + + -- Jamin W. Collins Sat, 1 Jan 2005 12:54:22 -0700 + +jabberd2 (2.0s4-2) experimental; urgency=low + + * added patch to correct mysql and pgsql buffer overflow (Closes: #283189) + + -- Jamin W. Collins Fri, 26 Nov 2004 23:58:22 -0700 + +jabberd2 (2.0s4-1) experimental; urgency=low + + * New upstream version (Closes: #279922, #275976) + * Upstream exception added for OpenSSL (Closes: #237303) + * updated default start/stop sequence to start after and + stop before mysql/pgsql (Closes: #250886) + * built packages offering ldap option (Closes: #256382, #279478) + * corrected typo referencing MSM instead of MSN in long descriptions + * added dependency on jabber-common + * components now run as jabber:adm (Closes: #245260) + + -- Jamin W. Collins Sat, 6 Nov 2004 14:59:13 -0700 + +jabberd2 (2.0s2-2) experimental; urgency=low + + * Added pam support to all versions + * updated long descriptions + * remove /var/lib/jabberd2/* from non bdb packages + * added /etc/jabbard2/sm.d directory to ease vhosting + + -- Jamin W. Collins Fri, 12 Mar 2004 11:26:25 -0700 + +jabberd2 (2.0s2-1) experimental; urgency=low + + * New upstream version + + -- Jamin W. Collins Mon, 1 Mar 2004 20:53:07 -0700 + +jabberd2 (2.0s1-1) unstable; urgency=low + + * First upstream stable release + + -- Jamin W. Collins Sat, 3 Jan 2004 12:56:59 -0700 + +jabberd2 (1+2.0.0-b3-1) unstable; urgency=low + + * new upstream version + + -- Jamin W. Collins Mon, 3 Nov 2003 23:49:00 -0700 + +jabberd2 (1+2.0.0-a6-2) unstable; urgency=low + + * removed libsasl2-dev build depends + * added option to init script for individual component stop/start + * added check for daemon binary to each component script + * added check for already running daemon to each component script + + -- Jamin W. Collins Tue, 19 Aug 2003 22:31:26 -0600 + +jabberd2 (1+2.0.0-a6-1) unstable; urgency=low + + * new upstream version + + -- Jamin W. Collins Fri, 8 Aug 2003 14:21:01 -0600 + +jabberd2 (1+2.0.0-a4-1) unstable; urgency=low + + * Initial Release. + + -- Jamin W. Collins Thu, 8 May 2003 14:31:28 -0600 + --- jabberd2-2.2.8.orig/debian/NEWS +++ jabberd2-2.2.8/debian/NEWS @@ -0,0 +1,42 @@ +jabberd2 (2.2.8-2) unstable; urgency=low + + Keep in mind that from jabberd2 2.1 series packages, the BerkeleyDB and + SQLite databases are in /var/lib/jabberd2 instead of /var/lib/jabberd2/db/. + I've just realized this, so if you are upgrading from jabberd2-ldap-bdb or + jabberd2-bdb move the .db files to the proper path. + + -- Jorge Salamero Sanz Mon, 04 May 2009 11:25:03 +0100 + +jabberd2 (2.1.24.1-1) unstable; urgency=low + + Major issues appear upgrading from 2.0 series to this one, see UPGRADE. + + /etc/jabberd2/component.d/ is intended for startup scripts for the various + transports but work is still needed on transports packages. + + -- Jorge Salamero Sanz Fri, 02 May 2008 19:27:21 +0200 + +jabberd2 (2.0s4-1) experimental; urgency=low + + Users upgrading from a previous version of jabberd2-bdb (anything that + used an older version of libdb) will need to manually recover their + Berkeley databases. This appears to be due to a problem with how + Jabberd2 interacts with it's Berkeley database. The database seems to + be left in an unclean state when Jabberd2 shuts down. This isn't a + problem for normal operation, but when the version of the Berkeley + database libraries changes the database isn't able to be automatically + upgraded. + + You'll need the db4.1-util (assuming 4.1 was your previous version + of libdb) package installed. Assumming you used the default database + storage location the following commands should be all that are needed + (you'll want to make sure to stop Jabberd2 first): + + cd /var/lib/jabberd2/db + db4.1_recover + + Now you should be able to start Jabberd2. I apologize for this + inconvenience and hope to have this corrected soon. + + -- Jamin W. Collins Sat, 6 Nov 2004 14:59:13 -0700 + --- jabberd2-2.2.8.orig/debian/rules +++ jabberd2-2.2.8/debian/rules @@ -0,0 +1,131 @@ +#!/usr/bin/make -f + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +include /usr/share/dpatch/dpatch.make + +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) + +CFLAGS = -Wall -g + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif + +ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS))) + CFLAGS += -g + CONFIGURE_EXTRA_FLAGS += --enable-debug +endif + +DEB_HOST_ARCH_OS := $(shell dpkg-architecture -qDEB_HOST_ARCH_OS 2>/dev/null) +ifeq ($(DEB_HOST_ARCH_OS), linux) + CONFIGURE_EXTRA_FLAGS += --enable-mio=epoll +endif + +config.status: patch configure + dh_testdir + + libtoolize --force --copy +ifneq "$(wildcard /usr/share/misc/config.sub)" "" + cp -f /usr/share/misc/config.sub config.sub +endif +ifneq "$(wildcard /usr/share/misc/config.guess)" "" + cp -f /usr/share/misc/config.guess config.guess +endif + + aclocal + autoconf + + CFLAGS="$(CFLAGS)" ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) \ + --prefix=/usr --sysconfdir=/etc/jabberd2 --bindir=\$${prefix}/sbin \ + --program-prefix=jabberd2- --disable-rpath \ + --enable-sasl=gsasl \ + --enable-ssl \ + --enable-mysql \ + --enable-pgsql \ + --enable-sqlite \ + --enable-db \ + --enable-ldap \ + --enable-pam \ + --enable-pipe \ + --enable-anon \ + --enable-fs \ + $(CONFIGURE_EXTRA_FLAGS) + +build: build-stamp + +build-stamp: config.status + dh_testdir + + $(MAKE) + + touch $@ + +clean: clean1 unpatch + +clean1: + dh_testdir + dh_testroot + rm -f build-stamp + + [ ! -f Makefile ] || $(MAKE) distclean + rm -f config.sub config.guess + + dh_clean + +install: + dh_testdir + dh_testroot + dh_prep + dh_installdirs + + $(MAKE) DESTDIR=$(CURDIR)/debian/jabberd2 install + + rm `find $(CURDIR)/debian/jabberd2 -name '*.la'` + # remove jabberd wrapper, we use lsb init scripts + rm $(CURDIR)/debian/jabberd2/etc/jabberd2/jabberd.cfg + rm $(CURDIR)/debian/jabberd2/usr/sbin/jabberd2-jabberd + # install component.d scripts + install -o root -g root -m 0755 debian/component.d/* $(CURDIR)/debian/jabberd2/etc/jabberd2/component.d + install -o root -g root -m 0755 -d $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/examples + mv $(CURDIR)/debian/jabberd2/etc/jabberd2/*.dist $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/examples/ + mv $(CURDIR)/debian/jabberd2/etc/jabberd2/templates/*.dist $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/examples/ + # install tools and stuff + cp $(CURDIR)/tools/*.sqlite $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + cp $(CURDIR)/tools/*.mysql $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + cp $(CURDIR)/tools/*.pgsql $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + cp $(CURDIR)/tools/*.oracle $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + cp $(CURDIR)/tools/*.sql $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + cp $(CURDIR)/tools/*.pl $(CURDIR)/debian/jabberd2/usr/share/doc/jabberd2/ + # lintian overrides + install -D -m 644 $(CURDIR)/debian/lintian-overrides $(CURDIR)/debian/jabberd2/usr/share/lintian/overrides/jabberd2 + +binary-indep: + +binary-arch: install + dh_testdir + dh_testroot + dh_installchangelogs ChangeLog + dh_installdocs + dh_installexamples + dh_install +# dh_installdebconf + dh_installlogrotate + dh_installinit + dh_installman + dh_link + dh_strip + dh_compress + dh_fixperms + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install --- jabberd2-2.2.8.orig/debian/prerm +++ jabberd2-2.2.8/debian/prerm @@ -0,0 +1,20 @@ +#!/bin/sh + +set -e + +case "$1" in + remove|upgrade) + ;; + + deconfigure|failed-upgrade) + ;; + + *) + echo "prerm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +#DEBHELPER# + +exit 0 --- jabberd2-2.2.8.orig/debian/copyright +++ jabberd2-2.2.8/debian/copyright @@ -0,0 +1,48 @@ +This package was debianized by Jorge Salamero Sanz on +Fri, 13 Jul 2007 17:32:28 +0000. + +Jamin W. Collins was the previous maintainer. + +It was downloaded from http://jabberd2.xiaoka.com/ + +Upstream Authors: + + Ryan Eatmon + Jeremie Miller + Thomas Muldowney + Robert Norris + Stephen Marquard + Tomasz Sterna + and others, see AUTHORS + +Copyright: + + Copyright (C) 2002-2004 Ryan Eatmon + Copyright (C) 2002-2004 Jeremie Miller + Copyright (C) 2002-2004 Thomas Muldowney + Copyright (C) 2002-2004 Robert Norris + +License: + + This package 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; version 2 dated June, 1991. + + 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 package; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, + MA 02110-1301, USA. + + As a special exception, the authors give permission to link this program + with the OpenSSL library and distribute the resulting binary. + +On Debian systems, the complete text of the GNU General Public License +can be found in the file `/usr/share/common-licenses/GPL-2'. + +The Debian packaging is (C) 2007, Jorge Salamero Sanz +and is licensed under the GPL, see `/usr/share/common-licenses/GPL-3'. --- jabberd2-2.2.8.orig/debian/lintian-overrides +++ jabberd2-2.2.8/debian/lintian-overrides @@ -0,0 +1,2 @@ +jabberd2 binary: possible-gpl-code-linked-with-openssl +jabberd2 binary: dir-or-file-in-var-run --- jabberd2-2.2.8.orig/debian/component.d/30sm +++ jabberd2-2.2.8/debian/component.d/30sm @@ -0,0 +1,44 @@ +#!/bin/sh + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +NAME=sm +COMMAND=/usr/sbin/jabberd2-${NAME} +PIDFILE=/var/run/jabberd2/${NAME}.pid +CONFFILE=/etc/jabberd2/${NAME}.xml + +# exit now if we are not ment to run +test "${SM_RUN}" != 0 || exit 0 + +# check for executable +test -f ${COMMAND} || exit 0 + +case "$1" in + start) + echo -n " ${NAME}" + if [ ! `pidof ${COMMAND}` ]; then + start-stop-daemon -b -c ${USER}:${GROUP} \ + --start --pidfile ${PIDFILE} --quiet \ + --exec ${COMMAND} -- -c ${CONFFILE} || echo -n "" + fi + ;; + stop) + echo -n " ${NAME}" + start-stop-daemon -o -u ${USER} --stop --quiet \ + --signal 15 --retry 3 --pidfile ${PIDFILE} \ + --exec ${COMMAND} || echo -n "" + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "`basename $0` called with unknown option {$1}" + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/component.d/20resolver +++ jabberd2-2.2.8/debian/component.d/20resolver @@ -0,0 +1,44 @@ +#!/bin/sh + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +NAME=resolver +COMMAND=/usr/sbin/jabberd2-${NAME} +PIDFILE=/var/run/jabberd2/${NAME}.pid +CONFFILE=/etc/jabberd2/${NAME}.xml + +# exit now if we are not ment to run +test "${RESOLVER_RUN}" != 0 || exit 0 + +# check for executable +test -f ${COMMAND} || exit 0 + +case "$1" in + start) + echo -n " ${NAME}" + if [ ! `pidof ${COMMAND}` ]; then + start-stop-daemon -b -c ${USER}:${GROUP} \ + --start --pidfile ${PIDFILE} --quiet \ + --exec ${COMMAND} -- -c ${CONFFILE} || echo -n "" + fi + ;; + stop) + echo -n " ${NAME}" + start-stop-daemon -o -u ${USER} --stop --quiet \ + --signal 15 --retry 3 --pidfile ${PIDFILE} \ + --exec ${COMMAND} || echo -n "" + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "`basename $0` called with unknown option {$1}" + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/component.d/40s2s +++ jabberd2-2.2.8/debian/component.d/40s2s @@ -0,0 +1,44 @@ +#!/bin/sh + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +NAME=s2s +COMMAND=/usr/sbin/jabberd2-${NAME} +PIDFILE=/var/run/jabberd2/${NAME}.pid +CONFFILE=/etc/jabberd2/${NAME}.xml + +# exit now if we are not ment to run +test "${S2S_RUN}" != 0 || exit 0 + +# check for executable +test -f ${COMMAND} || exit 0 + +case "$1" in + start) + echo -n " ${NAME}" + if [ ! `pidof ${COMMAND}` ]; then + start-stop-daemon -b -c ${USER}:${GROUP} \ + --start --pidfile ${PIDFILE} --quiet \ + --exec ${COMMAND} -- -c ${CONFFILE} || echo -n "" + fi + ;; + stop) + echo -n " ${NAME}" + start-stop-daemon -o -u ${USER} --stop --quiet \ + --signal 15 --retry 3 --pidfile ${PIDFILE} \ + --exec ${COMMAND} || echo -n "" + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "`basename $0` called with unknown option {$1}" + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/component.d/10router +++ jabberd2-2.2.8/debian/component.d/10router @@ -0,0 +1,44 @@ +#!/bin/sh + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +NAME=router +COMMAND=/usr/sbin/jabberd2-${NAME} +PIDFILE=/var/run/jabberd2/${NAME}.pid +CONFFILE=/etc/jabberd2/${NAME}.xml + +# exit now if we are not ment to run +test "${ROUTER_RUN}" != 0 || exit 0 + +# check for executable +test -f ${COMMAND} || exit 0 + +case "$1" in + start) + echo -n " ${NAME}" + if [ ! `pidof ${COMMAND}` ]; then + start-stop-daemon -b -c ${USER}:${GROUP} \ + --start --pidfile ${PIDFILE} --quiet \ + --exec ${COMMAND} -- -c ${CONFFILE} || echo -n "" + fi + ;; + stop) + echo -n " ${NAME}" + start-stop-daemon -o -u ${USER} --stop --quiet \ + --signal 15 --retry 3 --pidfile ${PIDFILE} \ + --exec ${COMMAND} || echo -n "" + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "`basename $0` called with unknown option {$1}" + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/component.d/50c2s +++ jabberd2-2.2.8/debian/component.d/50c2s @@ -0,0 +1,44 @@ +#!/bin/sh + +set -e + +test -f /etc/default/jabberd2 && . /etc/default/jabberd2 + +NAME=c2s +COMMAND=/usr/sbin/jabberd2-${NAME} +PIDFILE=/var/run/jabberd2/${NAME}.pid +CONFFILE=/etc/jabberd2/${NAME}.xml + +# exit now if we are not ment to run +test "${C2S_RUN}" != 0 || exit 0 + +# check for executable +test -f ${COMMAND} || exit 0 + +case "$1" in + start) + echo -n " ${NAME}" + if [ ! `pidof ${COMMAND}` ]; then + start-stop-daemon -b -c ${USER}:${GROUP} \ + --start --pidfile ${PIDFILE} --quiet \ + --exec ${COMMAND} -- -c ${CONFFILE} || echo -n "" + fi + ;; + stop) + echo -n " ${NAME}" + start-stop-daemon -o -u ${USER} --stop --quiet \ + --signal 15 --retry 3 --pidfile ${PIDFILE} \ + --exec ${COMMAND} || echo -n "" + ;; + restart) + $0 stop + sleep 1 + $0 start + ;; + *) + echo "`basename $0` called with unknown option {$1}" + exit 1 + ;; +esac + +exit 0 --- jabberd2-2.2.8.orig/debian/patches/CVE-2012-3525.dpatch +++ jabberd2-2.2.8/debian/patches/CVE-2012-3525.dpatch @@ -0,0 +1,28 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## CVE-2012-3525.dpatch by Jamie Strandboge +## +## Origin: backport, https://github.com/Jabberd2/jabberd2/commit/aabcffae560d5fd00cd1d2ffce5d760353cf0a4d +## Description: Fixed possibility of Unsolicited Dialback Attacks + +@DPATCH@ +diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' jabberd2-2.2.8~/s2s/out.c jabberd2-2.2.8/s2s/out.c +--- jabberd2-2.2.8~/s2s/out.c 2009-04-27 04:05:14.000000000 -0500 ++++ jabberd2-2.2.8/s2s/out.c 2012-08-23 08:05:21.194548703 -0500 +@@ -1621,7 +1621,7 @@ + rkey = s2s_route_key(NULL, to->domain, from->domain); + + /* key is valid */ +- if(nad_find_attr(nad, 0, -1, "type", "valid") >= 0) { ++ if(nad_find_attr(nad, 0, -1, "type", "valid") >= 0 && xhash_get(out->states, rkey) == (void*) conn_INPROGRESS) { + log_write(out->s2s->log, LOG_NOTICE, "[%d] [%s, port=%d] outgoing route '%s' is now valid%s", out->fd->fd, out->ip, out->port, rkey, (out->s->flags & SX_SSL_WRAPPER) ? ", TLS negotiated" : ""); + + xhash_put(out->states, pstrdup(xhash_pool(out->states), rkey), (void *) conn_VALID); /* !!! small leak here */ +@@ -1709,7 +1709,7 @@ + rkey = s2s_route_key(NULL, to->domain, from->domain); + + attr = nad_find_attr(nad, 0, -1, "type", "valid"); +- if(attr >= 0) { ++ if(attr >= 0 && xhash_get(in->states, rkey) == (void*) conn_INPROGRESS) { + xhash_put(in->states, pstrdup(xhash_pool(in->states), rkey), (void *) conn_VALID); + log_write(in->s2s->log, LOG_NOTICE, "[%d] [%s, port=%d] incoming route '%s' is now valid%s", in->fd->fd, in->ip, in->port, rkey, (in->s->flags & SX_SSL_WRAPPER) ? ", TLS negotiated" : ""); + valid = 1; --- jabberd2-2.2.8.orig/debian/patches/etc_pidpath.dpatch +++ jabberd2-2.2.8/debian/patches/etc_pidpath.dpatch @@ -0,0 +1,53 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## etc_pidpath.dpatch by Jorge Salamero Sanz +## DP: changes in etc files the path of logs + +@DPATCH@ +diff -urNad jabberd2~/etc/c2s.xml.dist.in jabberd2/etc/c2s.xml.dist.in +--- jabberd2~/etc/c2s.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/c2s.xml.dist.in 2009-04-17 18:26:44.000000000 +0100 +@@ -5,7 +5,7 @@ + + +- @localstatedir@/jabberd/pid/c2s.pid ++ /var/run/jabberd2/c2s.pid + + + +diff -urNad jabberd2~/etc/router.xml.dist.in jabberd2/etc/router.xml.dist.in +--- jabberd2~/etc/router.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/router.xml.dist.in 2009-04-17 18:26:44.000000000 +0100 +@@ -5,7 +5,7 @@ + + +- @localstatedir@/jabberd/pid/router.pid ++ /var/run/jabberd2/router.pid + + + +diff -urNad jabberd2~/etc/s2s.xml.dist.in jabberd2/etc/s2s.xml.dist.in +--- jabberd2~/etc/s2s.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/s2s.xml.dist.in 2009-04-17 18:26:44.000000000 +0100 +@@ -5,7 +5,7 @@ + + +- @localstatedir@/jabberd/pid/s2s.pid ++ /var/run/jabberd2/s2s.pid + + + +diff -urNad jabberd2~/etc/sm.xml.dist.in jabberd2/etc/sm.xml.dist.in +--- jabberd2~/etc/sm.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/sm.xml.dist.in 2009-04-17 18:26:44.000000000 +0100 +@@ -7,7 +7,7 @@ + + +- @localstatedir@/jabberd/pid/sm.pid ++ /var/run/jabberd2/sm.pid + + + --- jabberd2-2.2.8.orig/debian/patches/CVE-2011-1755.dpatch +++ jabberd2-2.2.8/debian/patches/CVE-2011-1755.dpatch @@ -0,0 +1,29 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## CVE-2011-1755.dpatch by Nico Golde +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: disable entity expansian to prevent billion laughs attack + +@DPATCH@ +diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' jabberd2-2.2.8~/sx/sx.c jabberd2-2.2.8/sx/sx.c +--- jabberd2-2.2.8~/sx/sx.c 2009-04-27 11:05:13.000000000 +0200 ++++ jabberd2-2.2.8/sx/sx.c 2011-05-30 23:40:27.000000000 +0200 +@@ -36,6 +36,7 @@ + s->expat = XML_ParserCreateNS(NULL, '|'); + XML_SetReturnNSTriplet(s->expat, 1); + XML_SetUserData(s->expat, (void *) s); ++ XML_SetDefaultHandler(s->expat, NULL); + + s->wbufq = jqueue_new(); + s->rnadq = jqueue_new(); +diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' jabberd2-2.2.8~/util/nad.c jabberd2-2.2.8/util/nad.c +--- jabberd2-2.2.8~/util/nad.c 2009-04-27 11:05:15.000000000 +0200 ++++ jabberd2-2.2.8/util/nad.c 2011-05-30 23:40:27.000000000 +0200 +@@ -1331,6 +1331,7 @@ + return NULL; + + XML_SetReturnNSTriplet(p, 1); ++ XML_SetDefaultHandler(p, NULL); + + bd.nad = nad_new(); + bd.depth = 0; --- jabberd2-2.2.8.orig/debian/patches/etc_logpath.dpatch +++ jabberd2-2.2.8/debian/patches/etc_logpath.dpatch @@ -0,0 +1,105 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## etc_logpath.dpatch by Jorge Salamero Sanz +## DP: changes in etc files the path of logs + +@DPATCH@ +diff -urNad jabberd2~/etc/c2s.xml.dist.in jabberd2/etc/c2s.xml.dist.in +--- jabberd2~/etc/c2s.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/c2s.xml.dist.in 2009-04-17 18:24:13.000000000 +0100 +@@ -50,7 +50,7 @@ + + + +- ++ + + jabberd/c2s + +@@ -59,9 +59,9 @@ + local3 + + +- ++ ++ /var/log/jabberd2/c2s.log ++ + + + +diff -urNad jabberd2~/etc/router.xml.dist.in jabberd2/etc/router.xml.dist.in +--- jabberd2~/etc/router.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/router.xml.dist.in 2009-04-17 18:24:13.000000000 +0100 +@@ -8,7 +8,7 @@ + @localstatedir@/jabberd/pid/router.pid + + +- ++ + + jabberd/router + +@@ -17,9 +17,9 @@ + local3 + + +- ++ ++ /var/log/jabberd2/router.log ++ + + + +diff -urNad jabberd2~/etc/s2s.xml.dist.in jabberd2/etc/s2s.xml.dist.in +--- jabberd2~/etc/s2s.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/s2s.xml.dist.in 2009-04-17 18:24:13.000000000 +0100 +@@ -60,7 +60,7 @@ + + + +- ++ + + jabberd/s2s + +@@ -69,9 +69,9 @@ + local3 + + +- ++ ++ /var/log/jabberd2/s2s.log ++ + + + +diff -urNad jabberd2~/etc/sm.xml.dist.in jabberd2/etc/sm.xml.dist.in +--- jabberd2~/etc/sm.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/sm.xml.dist.in 2009-04-17 18:24:13.000000000 +0100 +@@ -52,7 +52,7 @@ + + + +- ++ + + jabberd/sm + +@@ -61,9 +61,9 @@ + local3 + + +- ++ ++ /var/log/jabberd2/sm.log ++ + + + --- jabberd2-2.2.8.orig/debian/patches/00list +++ jabberd2-2.2.8/debian/patches/00list @@ -0,0 +1,7 @@ +pkgname.dpatch +etc_pidpath.dpatch +etc_logpath.dpatch +etc_dbpath.dpatch +implicit-pointer-conversion.dpatch +CVE-2011-1755.dpatch +CVE-2012-3525 --- jabberd2-2.2.8.orig/debian/patches/etc_dbpath.dpatch +++ jabberd2-2.2.8/debian/patches/etc_dbpath.dpatch @@ -0,0 +1,47 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## etc_dbpath.dpatch by Jorge Salamero Sanz +## DP: changes in etc files the path of databases + +@DPATCH@ +diff -urNad jabberd2~/etc/c2s.xml.dist.in jabberd2/etc/c2s.xml.dist.in +--- jabberd2~/etc/c2s.xml.dist.in 2009-02-24 22:28:35.000000000 +0000 ++++ jabberd2/etc/c2s.xml.dist.in 2009-04-17 18:23:54.000000000 +0100 +@@ -435,7 +435,7 @@ + + + +- @localstatedir@/jabberd/db/sqlite.db ++ /var/lib/jabberd2/sqlite.db + + + + +- @localstatedir@/jabberd/db ++ /var/lib/jabberd2/ + + + + +- @localstatedir@/jabberd/db ++ /var/lib/jabberd2/ + + + + +- @localstatedir@/jabberd/db/sqlite.db ++ /var/lib/jabberd2/sqlite.db + +