--- ebox-openvpn-1.3.5.orig/debian/ebox-openvpn.postrm +++ ebox-openvpn-1.3.5/debian/ebox-openvpn.postrm @@ -0,0 +1,26 @@ +#!/bin/bash + +set -e + +# We need to unconfigure and purge module's configuration +# before the gconf schemas have been removed (i.e before gconf +# debhelper has been run). That's why we do things before +# and after gconf debhelper is run +if [ "$1" = "purge" ]; then + # Purge configuration + /usr/share/ebox/ebox-clean-gconf openvpn || true +fi + + +#DEBHELPER# + +case "$1" in + remove) + # openvpn changes network interfaces so we must restart network module to propagate the changes + invoke-rc.d ebox network restart || true + + dpkg-trigger --no-await ebox + ;; +esac + + --- ebox-openvpn-1.3.5.orig/debian/control +++ ebox-openvpn-1.3.5/debian/control @@ -0,0 +1,20 @@ +Source: ebox-openvpn +Section: web +Priority: optional +Maintainer: Ubuntu MOTU Developers +XSBC-Original-Maintainer: Javier Uruen Val +Build-Depends: debhelper (>= 5.0.0), autotools-dev, cdbs +Standards-Version: 3.8.2 + +Package: ebox-openvpn +Architecture: all +Depends: ebox (>= 1.3), ebox (<< 1.4), openvpn, zip, ebox-firewall, ebox-ca, quagga, openssl, ${misc:Depends} +Replaces: ebox (<< 0.9.99) +Conflicts: ebox (<< 0.9.99) +Description: eBox - VPN Service + eBox is a framework for the development and deployment of security-wise + network services in small and medium-sized networks, offering a simplified + graphical interface to non expert users. It can be set up as a gateway, + having some extra features over a usual router. + . + This module adds a OpenVPN server to eBox. --- ebox-openvpn-1.3.5.orig/debian/rules +++ ebox-openvpn-1.3.5/debian/rules @@ -0,0 +1,6 @@ +#!/usr/bin/make -f + +include /usr/share/cdbs/1/rules/debhelper.mk +include /usr/share/cdbs/1/class/autotools.mk +include /usr/share/cdbs/1/rules/simple-patchsys.mk +include debian/cdbs/ebox.mk --- ebox-openvpn-1.3.5.orig/debian/copyright +++ ebox-openvpn-1.3.5/debian/copyright @@ -0,0 +1,30 @@ +This package was debianized by Javier Amor on +Fri, 20 Aug 2006 14:10:24 +0100. +It's currently maintained by Javier Uruen Val + +It was downloaded from http://www.ebox-platform.com/ + +Upstream Author: Warp Networks S.L. + +Copyright (C) 2004 Warp Networks S.L. + +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. + + On Debian systems, the complete text of the GNU General Public + License can be found in /usr/share/common-licenses/GPL file. + +The Debian packaging is: + + (C) 2004, Isaac Clerencia + (C) 2008, Javier Uruen Val + +and is licensed under the GPL, see `/usr/share/common-licenses/GPL'. --- ebox-openvpn-1.3.5.orig/debian/ebox-openvpn.postinst +++ ebox-openvpn-1.3.5/debian/ebox-openvpn.postinst @@ -0,0 +1,44 @@ +#!/bin/bash +set -e + +#DEBHELPER# + +case "$1" in + configure) + kill `pidof gconfd-2` >/dev/null 2>&1 || true + + # add a tun device if not exists + #[ -e /dev/net ] || mkdir -m 755 /dev/net + #[ -d /dev/net -a ! -e /dev/net/tun ] && /bin/mknod /dev/net/tun c 10 200 + + # create diffie-hellman parameters if needed + DH_FILE='/etc/openvpn/ebox-dh1024.pem' + if [ -e $DH_FILE ]; then + echo "We assume $DH_FILE is a Diffie-Hellman parameter file with 1024 byte length. If the assumption is false, please remove it and create a new one manually. If you do NOT do so, your OpenVPN tunnels may be compromised" + else + openssl dhparam -out $DH_FILE 1024 + fi + + + # create openvpn status log directory + STATUS_DIR=`perl -MEBox::OpenVPN -e 'print EBox::OpenVPN->logDir(); 1 '` + test -d $STATUS_DIR || mkdir -p $STATUS_DIR + chown nobody:nogroup $STATUS_DIR + + + # create log table + /usr/share/ebox/ebox-sql-table add openvpn /usr/share/ebox/sqllog/openvpn.sql || true + + # migrate data if needed + /usr/share/ebox/ebox-migrate /usr/share/ebox-openvpn/migration/ || true + # restart logs + invoke-rc.d ebox logs restart || true + # restart module + invoke-rc.d ebox openvpn restart || true + # restart module + invoke-rc.d ebox firewall restart || true + + dpkg-trigger --no-await ebox + esac + +exit 0 --- ebox-openvpn-1.3.5.orig/debian/dirs +++ ebox-openvpn-1.3.5/debian/dirs @@ -0,0 +1,2 @@ +usr/bin +usr/sbin --- ebox-openvpn-1.3.5.orig/debian/watch +++ ebox-openvpn-1.3.5/debian/watch @@ -0,0 +1,3 @@ +version=3 + +http://ebox-platform.com/releases/sources/latest/ebox-openvpn-(\d[\d_.-]+)\.tar.gz --- ebox-openvpn-1.3.5.orig/debian/compat +++ ebox-openvpn-1.3.5/debian/compat @@ -0,0 +1 @@ +5 --- ebox-openvpn-1.3.5.orig/debian/changelog +++ ebox-openvpn-1.3.5/debian/changelog @@ -0,0 +1,142 @@ +ebox-openvpn (1.3.5-0ubuntu1) karmic; urgency=low + + [Javier Uruen Val] + * New upstream release [LP: 411551] + * cdbs/ebox.mk + - GConf schemas are not used anymore + - Remove SCHEMASPATH variable + - Remove schemadir variable + - Use new upstart directory and file naming convention + * debian/control + - Bump standards version + - Bump eBox depenency + * debian/ebox-openvpn.postinst + - Fix indentation + - Do not pkill gconfd as it's not necessary anymore + - Run ebox trigger + - Add set -e + - Add || true + * debian/ebox-openvpn.postrm + - Run ebox trigger + - Add set -e + * remove debian/ebox-openvpn.prerm + - Not needed anymore as we don't use gconf schemas + * debian/patches + - Use simple-patchsys + - Add 01_fix_upstart.patch + * debian/rules + - Do not include debian/cdbs/gnome.mk + - Include /usr/share/cdbs/1/rules/simple-patchsys.mk + * debian/watch + - Change URL + + -- Javier Uruen Val Wed, 05 Aug 2009 12:29:43 +0200 + +ebox-openvpn (0.12-0ubuntu1) jaunty; urgency=low + + [ Javier Uruen Val ] + * New upstream release. Closes (LP: #318814) + * debian/watch: + - add watch file. + + -- Mathias Gug Mon, 26 Jan 2009 21:53:47 -0500 + +ebox-openvpn (0.11.99-0ubuntu4) hardy; urgency=low + + * Acutally add the patches. + + -- Chuck Short Thu, 10 Apr 2008 11:32:02 -0400 + +ebox-openvpn (0.11.99-0ubuntu3) hardy; urgency=low + + * debian/patches/02_fix_enable_service.dpatch. + - Fix issue that prevented openVPNs from starting. + + -- Chuck Short Thu, 10 Apr 2008 11:10:52 -0400 + +ebox-openvpn (0.11.99-0ubuntu2) hardy; urgency=low + + * debian/ebox-openvpn.postinst + - Create eBox openVPN Diffie-Hellman file. + * debian/patches/01_prepare_log_files.dpatch + - Fix to prepare log files permissions to be read by loggered. + + -- Chuck Short Mon, 24 Mar 2008 08:58:21 -0400 + +ebox-openvpn (0.11.99-0ubuntu1) hardy; urgency=low + + * New upstream version. + + -- Chuck Short Wed, 27 Feb 2008 13:31:29 -0500 + +ebox-openvpn (0.11.99-0ubuntu1~ppa1) hardy; urgency=low + + * New upstream release + + -- Javier Uruen Val Mon, 25 Feb 2008 15:01:13 +0100 + +ebox-openvpn (0.11.99) unstable; urgency=low + + * New upstream release + + -- Enrique José Hernández Blasco Tue, 8 Jan 2008 16:14:39 +0100 + +ebox-openvpn (0.11-0ubuntu1~ppa1) hardy; urgency=low + + * New upstream release + + -- Javier Uruen Val Wed, 28 Nov 2007 15:23:34 +0100 + +ebox-openvpn (0.10.99) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Thu, 01 Nov 2007 21:38:14 +0100 + +ebox-openvpn (0.10) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Wed, 10 Oct 2007 21:53:51 +0200 + +ebox-openvpn (0.9.100) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Tue, 04 Sep 2007 14:19:31 +0200 + +ebox-openvpn (0.9.99) unstable; urgency=low + + * New upstream release + + -- Javier Amor Garcia Tue, 24 Jul 2007 12:54:17 +0200 + +ebox-openvpn (0.9.3) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Sun, 24 Jun 2007 16:38:48 +0200 + +ebox-openvpn (0.9.2) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Tue, 12 Jun 2007 18:59:28 +0200 + +ebox-openvpn (0.9.1) unstable; urgency=low + + * New upstream release + + -- Javier Uruen Val Tue, 15 May 2007 13:02:26 +0200 + +ebox-openvpn (0.9) unstable; urgency=low + + * New upstream release + + -- Javier Amor Garcia Tue, 27 Mar 2007 16:16:29 +0200 + +ebox-openvpn (0.8.99) unstable; urgency=low + + * Initial upstream release + + -- Javier Amor Garcia Tue, 6 Feb 2007 10:39:51 +0100 --- ebox-openvpn-1.3.5.orig/debian/cdbs/ebox.mk +++ ebox-openvpn-1.3.5/debian/cdbs/ebox.mk @@ -0,0 +1,28 @@ +DEB_CONFIGURE_SCRIPT_ENV += LOGPATH="/var/log/ebox" +DEB_CONFIGURE_SCRIPT_ENV += CONFPATH="/var/lib/ebox/conf" +DEB_CONFIGURE_SCRIPT_ENV += STUBSPATH="/usr/share/ebox/stubs" +DEB_CONFIGURE_SCRIPT_ENV += CGIPATH="/usr/share/ebox/cgi/" +DEB_CONFIGURE_SCRIPT_ENV += TEMPLATESPATH="/usr/share/ebox/templates" +DEB_CONFIGURE_SCRIPT_ENV += WWWPATH="/usr/share/ebox/www/" +DEB_CONFIGURE_SCRIPT_ENV += CSSPATH="/usr/share/ebox/www/css" +DEB_CONFIGURE_SCRIPT_ENV += IMAGESPATH="/usr/share/ebox/www/images" +DEB_CONFIGURE_SCRIPT_ENV += VARPATH="/var" +DEB_CONFIGURE_SCRIPT_ENV += ETCPATH="/etc/ebox" +DEB_CONFIGURE_SCRIPT_ENV += BIND9CONFDIR="/etc/bind" +DEB_CONFIGURE_SCRIPT_ENV += BIND9CONF="/etc/bind/named.conf" +DEB_CONFIGURE_SCRIPT_ENV += BIND9CONFOPTIONS="/etc/bind/named.conf.options" +DEB_CONFIGURE_SCRIPT_ENV += BIND9CONFLOCAL="/etc/bind/named.conf.local" +DEB_CONFIGURE_SCRIPT_ENV += BIND9_INIT="/etc/init.d/bind9" + +DEB_CONFIGURE_EXTRA_FLAGS := --disable-runtime-tests +DEB_MAKE_INVOKE = $(MAKE) $(DEB_MAKE_FLAGS) -C $(DEB_BUILDDIR) + +$(patsubst %,binary-install/%,$(DEB_PACKAGES)) :: binary-install/%: + for event in debian/*.upstart ; do \ + [ -f $$event ] || continue; \ + install -d -m 755 debian/$(cdbs_curpkg)/etc/init; \ + DESTFILE=$$(basename $$(echo $$event | sed 's/\.upstart/.conf/g')); \ + install -m 644 "$$event" debian/$(cdbs_curpkg)/etc/init/$$DESTFILE; \ + done;\ + rm -rf debian/$(cdbs_curpkg)/usr/bin \ + rm -rf debian/$(cdbs_curpkg)/usr/sbin --- ebox-openvpn-1.3.5.orig/debian/patches/01_fix_upstart.patch +++ ebox-openvpn-1.3.5/debian/patches/01_fix_upstart.patch @@ -0,0 +1,28 @@ +## 01_fix_upstart.patch by Javier Uruen Val +## +## DP: Upstart version shipped in karmic has changed its directory +## DP: from /etc/init to /etc/event.d, and also the script naming. +## DP: This patch fixes those two issues + +@DPATCH@ +diff -urNad ebox-openvpn-1.3.5~/src/EBox/OpenVPN/Daemon.pm ebox-openvpn-1.3.5/src/EBox/OpenVPN/Daemon.pm +--- ebox-openvpn-1.3.5~/src/EBox/OpenVPN/Daemon.pm 2009-02-26 16:50:32.000000000 +0100 ++++ ebox-openvpn-1.3.5/src/EBox/OpenVPN/Daemon.pm 2009-08-12 20:52:55.000000000 +0200 +@@ -12,7 +12,7 @@ + use EBox::NetWrappers; + use EBox::Service; + +-use constant UPSTART_DIR => '/etc/event.d'; ++use constant UPSTART_DIR => '/etc/init'; + + sub new + { +@@ -121,7 +121,7 @@ + sub _upstartFile + { + my ($self) = @_; +- return UPSTART_DIR . '/' . $self->upstartName(); ++ return UPSTART_DIR . '/' . $self->upstartName() . '.conf'; + } + + sub _upstartFileForDaemon