From c0a4b09f12434f62a455c22dc6b093b9871d67aa Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Wed, 19 Nov 2008 14:45:37 +0000 Subject: [PATCH 01/54] initial commit --- .cvsignore | 1 + import.log | 1 + sources | 1 + vtun.spec | 79 ++++++++++++++++++++++++++++++++++++++ vtund.init | 110 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 192 insertions(+) create mode 100644 import.log create mode 100644 vtun.spec create mode 100644 vtund.init diff --git a/.cvsignore b/.cvsignore index e69de29..1b3feab 100644 --- a/.cvsignore +++ b/.cvsignore @@ -0,0 +1 @@ +vtun-3.0.1.tar.gz diff --git a/import.log b/import.log new file mode 100644 index 0000000..25326c0 --- /dev/null +++ b/import.log @@ -0,0 +1 @@ +vtun-3_0_1-3_fc8:HEAD:vtun-3.0.1-3.fc8.src.rpm:1227105889 diff --git a/sources b/sources index e69de29..6c68109 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +c342ffe77055d4248a38f0b380f28c1b vtun-3.0.1.tar.gz diff --git a/vtun.spec b/vtun.spec new file mode 100644 index 0000000..0a34781 --- /dev/null +++ b/vtun.spec @@ -0,0 +1,79 @@ +Name: vtun +Version: 3.0.1 +Release: 3%{?dist} +Summary: Virtual tunnel over TCP/IP networks +License: GPLv2+ +Group: System Environment/Daemons +Url: http://vtun.sourceforge.net +Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz +Source1: vtund.init +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +Requires: xinetd +Requires(post): /sbin/chkconfig +Requires(preun): /sbin/service /sbin/chkconfig +Requires(postun): /sbin/service +BuildRequires: zlib-devel lzo-devel openssl-devel bison flex + +%description +VTun provides a method for creating Virtual Tunnels over TCP/IP networks +and allows one to shape, compress, and encrypt traffic in those tunnels. +Supported types of tunnels are: PPP, IP, Ethernet and most other serial +protocols and programs. +VTun is easily and highly configurable: it can be used for various +network tasks like VPN, Mobile IP, Shaped Internet access, IP address +saving, etc. It is completely a user space implementation and does not +require modification to any kernel parts. + +%prep +%setup -q + +%build +%configure +%{__make} %{?_smp_mflags} + +%install +%{__rm} -rf %{buildroot} +%{__install} -D -m 0755 -p %{SOURCE1} %{buildroot}/%{_initrddir}/vtund +%{__install} -D -m 0644 -p scripts/vtund.xinetd %{buildroot}/%{_sysconfdir}/xinetd.d/vtun +%{__sed} -i 's:/usr/local:%{_prefix}:' %{buildroot}/%{_sysconfdir}/xinetd.d/vtun +%{__make} install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" + +%clean +%{__rm} -rf %{buildroot} + +%post +if [ $1 -eq 1 ]; then + /sbin/chkconfig --add vtund || : +fi + +%preun +if [ $1 -eq 0 ]; then + /sbin/service vtund stop >/dev/null 2>&1 || : + /sbin/chkconfig --del vtund || : +fi + +%postun +if [ $1 -eq 1 ]; then + /sbin/service vtund condrestart >/dev/null 2>&1 || : +fi + +%files +%defattr(-,root,root,-) +%doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf +%config(noreplace) %{_sysconfdir}/vtund.conf +%config(noreplace) %{_sysconfdir}/xinetd.d/vtun +%{_initrddir}/vtund +%{_sbindir}/vtund +%dir %{_localstatedir}/log/vtund +%dir %{_localstatedir}/lock/vtund +%{_mandir}/man5/vtund.conf.5* +%{_mandir}/man8/vtun.8* +%{_mandir}/man8/vtund.8* + +%changelog +* Mon Nov 17 2008 Gabriel Somlo 3.0.1-3 +- scriptlets fixes +* Fri Nov 14 2008 Gabriel Somlo 3.0.1-2 +- spec file fixes: defattr, -p flag to install program +* Mon Oct 20 2008 Gabriel Somlo 3.0.1-1 +- initial fedora package diff --git a/vtund.init b/vtund.init new file mode 100644 index 0000000..13f22bc --- /dev/null +++ b/vtund.init @@ -0,0 +1,110 @@ +#!/bin/sh +# +# vtund Startup script for the virtual tunnel daemon +# +# chkconfig: - 55 45 +# description: Virtual Tunnel Daemon provides the facility to create \ +# virtual tunnels over TCP/IP networks and allows for \ +# shaping, compression, and encryption of tunneled traffic. + +### BEGIN INIT INFO +# Provides: +# Required-Start: +# Required-Stop: +# Should-Start: +# Should-Stop: +# Default-Start: +# Default-Stop: +# Short-Description: +# Description: +### END INIT INFO + +# Source function library. +. /etc/rc.d/init.d/functions + +exec="/usr/sbin/vtund" +prog="vtund" +config="/etc/vtund.conf" + +[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog + +lockfile=/var/lock/subsys/$prog + +start() { + [ -x $exec ] || exit 5 + [ -f $config ] || exit 6 + echo -n $"Starting $prog: " + daemon $exec -s + retval=$? + echo + [ $retval -eq 0 ] && touch $lockfile + return $retval +} + +stop() { + echo -n $"Stopping $prog: " + killproc $prog + retval=$? + echo + [ $retval -eq 0 ] && rm -f $lockfile + return $retval +} + +restart() { + stop + start +} + +reload() { + echo -n $"Reloading config for $prog: " + killproc $prog -HUP + retval=$? + echo + return $retval +} + +force_reload() { + restart +} + +rh_status() { + # run checks to determine if the service is running or use generic status + status $prog +} + +rh_status_q() { + rh_status >/dev/null 2>&1 +} + + +case "$1" in + start) + rh_status_q && exit 0 + $1 + ;; + stop) + rh_status_q || exit 0 + $1 + ;; + restart) + $1 + ;; + reload) + rh_status_q || exit 7 + $1 + ;; + force-reload) + force_reload + ;; + status) + rh_status + ;; + condrestart|try-restart) + rh_status_q || exit 0 + restart + ;; + *) + echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}" + exit 2 +esac +exit $? From b2bc09e589e3514ea1b1d75c9397f2de2d3fd8d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Mr=C3=A1z?= Date: Sun, 18 Jan 2009 15:06:05 +0000 Subject: [PATCH 02/54] - rebuild with new openssl --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 0a34781..311a89c 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -71,6 +71,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sun Jan 18 2009 Tomas Mraz 3.0.1-4 +- rebuild with new openssl + * Mon Nov 17 2008 Gabriel Somlo 3.0.1-3 - scriptlets fixes * Fri Nov 14 2008 Gabriel Somlo 3.0.1-2 From e20b1b2c3f539d245315c845cb9e09adb91aea92 Mon Sep 17 00:00:00 2001 From: Jesse Keating Date: Thu, 26 Feb 2009 00:58:43 +0000 Subject: [PATCH 03/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 311a89c..111643b 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -71,6 +71,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Wed Feb 25 2009 Fedora Release Engineering - 3.0.1-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + * Sun Jan 18 2009 Tomas Mraz 3.0.1-4 - rebuild with new openssl From 09bf4f879e169677e515c2c4b8b2dfa423043401 Mon Sep 17 00:00:00 2001 From: Jesse Keating Date: Mon, 27 Jul 2009 07:00:12 +0000 Subject: [PATCH 04/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 111643b..ad42da3 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -71,6 +71,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sun Jul 26 2009 Fedora Release Engineering - 3.0.1-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + * Wed Feb 25 2009 Fedora Release Engineering - 3.0.1-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild From 8d0f4ac48b8e0d83165453eef8ded64bc6354c2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Mr=C3=A1z?= Date: Fri, 21 Aug 2009 16:23:18 +0000 Subject: [PATCH 05/54] - rebuilt with new openssl --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index ad42da3..98fdae6 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 6%{?dist} +Release: 7%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -71,6 +71,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Fri Aug 21 2009 Tomas Mraz - 3.0.1-7 +- rebuilt with new openssl + * Sun Jul 26 2009 Fedora Release Engineering - 3.0.1-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild From 925b8ac123d8863b43519e62430a70c2cbe7f74c Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Wed, 25 Nov 2009 22:43:24 +0000 Subject: [PATCH 06/54] Fix typo that causes a failure to update the common directory. (releng #2781) --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 68b6d3f..5e77816 100644 --- a/Makefile +++ b/Makefile @@ -1,10 +1,10 @@ # Makefile for source rpm: vtun -# $Id$ +# $Id: Makefile,v 1.1 2008/11/19 01:43:25 kevin Exp $ NAME := vtun SPECFILE = $(firstword $(wildcard *.spec)) define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done +for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done endef MAKEFILE_COMMON := $(shell $(find-makefile-common)) From a5773110a4d891214a505039e0b9fbc6fd6bf9b2 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 29 Jul 2010 15:10:25 +0000 Subject: [PATCH 07/54] dist-git conversion --- .cvsignore => .gitignore | 0 Makefile | 21 --------------------- import.log | 1 - 3 files changed, 22 deletions(-) rename .cvsignore => .gitignore (100%) delete mode 100644 Makefile delete mode 100644 import.log diff --git a/.cvsignore b/.gitignore similarity index 100% rename from .cvsignore rename to .gitignore diff --git a/Makefile b/Makefile deleted file mode 100644 index 5e77816..0000000 --- a/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# Makefile for source rpm: vtun -# $Id: Makefile,v 1.1 2008/11/19 01:43:25 kevin Exp $ -NAME := vtun -SPECFILE = $(firstword $(wildcard *.spec)) - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attept a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/import.log b/import.log deleted file mode 100644 index 25326c0..0000000 --- a/import.log +++ /dev/null @@ -1 +0,0 @@ -vtun-3_0_1-3_fc8:HEAD:vtun-3.0.1-3.fc8.src.rpm:1227105889 From 8657652c0537fe13ea97dcafca3260c0c4be0fd3 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Tue, 30 Nov 2010 12:18:29 -0500 Subject: [PATCH 08/54] using %ghost on /var/lock/vtund directory (BZ 656720) --- .gitignore | 1 + vtun.spec | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 1b3feab..78cf322 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ vtun-3.0.1.tar.gz +/vtun-3.0.1.tar.gz diff --git a/vtun.spec b/vtun.spec index 98fdae6..ec7a87d 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -65,12 +65,15 @@ fi %{_initrddir}/vtund %{_sbindir}/vtund %dir %{_localstatedir}/log/vtund -%dir %{_localstatedir}/lock/vtund +%ghost %dir %{_localstatedir}/lock/vtund %{_mandir}/man5/vtund.conf.5* %{_mandir}/man8/vtun.8* %{_mandir}/man8/vtund.8* %changelog +* Tue Nov 30 2010 Gabriel Somlo 3.0.1-8 +- using %ghost on /var/lock/vtund directory (BZ 656720) + * Fri Aug 21 2009 Tomas Mraz - 3.0.1-7 - rebuilt with new openssl @@ -85,7 +88,9 @@ fi * Mon Nov 17 2008 Gabriel Somlo 3.0.1-3 - scriptlets fixes + * Fri Nov 14 2008 Gabriel Somlo 3.0.1-2 - spec file fixes: defattr, -p flag to install program + * Mon Oct 20 2008 Gabriel Somlo 3.0.1-1 - initial fedora package From be06e01b13480f9a661b8ed4cb454ca57a70d999 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Thu, 6 Jan 2011 16:18:18 -0500 Subject: [PATCH 09/54] add support for systemd (#661331) --- vtun.spec | 18 +++++++++++++++--- vtund.systemd | 10 ++++++++++ 2 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 vtund.systemd diff --git a/vtun.spec b/vtun.spec index ec7a87d..3b5abb1 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,17 +1,21 @@ Name: vtun Version: 3.0.1 -Release: 8%{?dist} +Release: 9%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtund.init +Source2: vtund.systemd BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: xinetd Requires(post): /sbin/chkconfig -Requires(preun): /sbin/service /sbin/chkconfig +Requires(preun): /sbin/chkconfig +Requires(preun): /sbin/service +Requires(preun): systemd-units Requires(postun): /sbin/service +Requires(postun): systemd-units BuildRequires: zlib-devel lzo-devel openssl-devel bison flex %description @@ -34,6 +38,7 @@ require modification to any kernel parts. %install %{__rm} -rf %{buildroot} %{__install} -D -m 0755 -p %{SOURCE1} %{buildroot}/%{_initrddir}/vtund +%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/lib/systemd/system/vtund.service %{__install} -D -m 0644 -p scripts/vtund.xinetd %{buildroot}/%{_sysconfdir}/xinetd.d/vtun %{__sed} -i 's:/usr/local:%{_prefix}:' %{buildroot}/%{_sysconfdir}/xinetd.d/vtun %{__make} install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" @@ -50,11 +55,14 @@ fi if [ $1 -eq 0 ]; then /sbin/service vtund stop >/dev/null 2>&1 || : /sbin/chkconfig --del vtund || : + /bin/systemctl disable vtund.service >/dev/null 2>&1 || : + /bin/systemctl stop vtund.service >/dev/null 2>&1 || : fi %postun if [ $1 -eq 1 ]; then /sbin/service vtund condrestart >/dev/null 2>&1 || : + /bin/systemctl try-restart vtund.service >/dev/null 2>&1 || : fi %files @@ -63,6 +71,7 @@ fi %config(noreplace) %{_sysconfdir}/vtund.conf %config(noreplace) %{_sysconfdir}/xinetd.d/vtun %{_initrddir}/vtund +/lib/systemd/system/vtund.service %{_sbindir}/vtund %dir %{_localstatedir}/log/vtund %ghost %dir %{_localstatedir}/lock/vtund @@ -71,8 +80,11 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Thu Jan 06 2011 Gabriel Somlo 3.0.1-9 +- add support for systemd (#661331) + * Tue Nov 30 2010 Gabriel Somlo 3.0.1-8 -- using %ghost on /var/lock/vtund directory (BZ 656720) +- using %ghost on /var/lock/vtund directory (#656720) * Fri Aug 21 2009 Tomas Mraz - 3.0.1-7 - rebuilt with new openssl diff --git a/vtund.systemd b/vtund.systemd new file mode 100644 index 0000000..47f7bc8 --- /dev/null +++ b/vtund.systemd @@ -0,0 +1,10 @@ +[Unit] +Description=virtual tunnel daemon +After=syslog.target network.target + +[Service] +Type=forking +ExecStart=/usr/sbin/vtund -s + +[Install] +WantedBy=multi-user.target From 1818248db3c09af53729e4cf6023bf357292ebe7 Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Mon, 7 Feb 2011 22:40:21 -0600 Subject: [PATCH 10/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 3b5abb1..0e8aa98 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 9%{?dist} +Release: 10%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -80,6 +80,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Mon Feb 07 2011 Fedora Release Engineering - 3.0.1-10 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + * Thu Jan 06 2011 Gabriel Somlo 3.0.1-9 - add support for systemd (#661331) From b3fcd3083fc3145922d05ded728c26d1f9cd15d3 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 10 Sep 2011 09:46:28 -0400 Subject: [PATCH 11/54] update support for systemd (#737195) --- vtun.service | 7 +++++++ vtun.socket | 9 +++++++++ vtun.spec | 13 +++++++++---- vtund.systemd | 10 ---------- 4 files changed, 25 insertions(+), 14 deletions(-) create mode 100644 vtun.service create mode 100644 vtun.socket delete mode 100644 vtund.systemd diff --git a/vtun.service b/vtun.service new file mode 100644 index 0000000..d872e6f --- /dev/null +++ b/vtun.service @@ -0,0 +1,7 @@ +[Unit] +Description=Virtual Tunnels over TCP/IP networks +After=local-fs.target + +[Service] +ExecStart=/usr/sbin/vtund -i +StandardInput=socket diff --git a/vtun.socket b/vtun.socket new file mode 100644 index 0000000..0dd22f9 --- /dev/null +++ b/vtun.socket @@ -0,0 +1,9 @@ +[Unit] +Description=Vtun Activation Socket + +[Socket] +ListenStream=5000 +Accept=true + +[Install] +WantedBy=sockets.target diff --git a/vtun.spec b/vtun.spec index 0e8aa98..86d2d5d 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,13 +1,14 @@ Name: vtun Version: 3.0.1 -Release: 10%{?dist} +Release: 11%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtund.init -Source2: vtund.systemd +Source2: vtun.socket +Source3: vtun.service BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: xinetd Requires(post): /sbin/chkconfig @@ -16,7 +17,7 @@ Requires(preun): /sbin/service Requires(preun): systemd-units Requires(postun): /sbin/service Requires(postun): systemd-units -BuildRequires: zlib-devel lzo-devel openssl-devel bison flex +BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units %description VTun provides a method for creating Virtual Tunnels over TCP/IP networks @@ -38,7 +39,8 @@ require modification to any kernel parts. %install %{__rm} -rf %{buildroot} %{__install} -D -m 0755 -p %{SOURCE1} %{buildroot}/%{_initrddir}/vtund -%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/lib/systemd/system/vtund.service +%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.socket +%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service %{__install} -D -m 0644 -p scripts/vtund.xinetd %{buildroot}/%{_sysconfdir}/xinetd.d/vtun %{__sed} -i 's:/usr/local:%{_prefix}:' %{buildroot}/%{_sysconfdir}/xinetd.d/vtun %{__make} install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" @@ -80,6 +82,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sat Sep 10 2011 Gabriel Somlo 3.0.1-11 +- update support for systemd (#737195) + * Mon Feb 07 2011 Fedora Release Engineering - 3.0.1-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild diff --git a/vtund.systemd b/vtund.systemd deleted file mode 100644 index 47f7bc8..0000000 --- a/vtund.systemd +++ /dev/null @@ -1,10 +0,0 @@ -[Unit] -Description=virtual tunnel daemon -After=syslog.target network.target - -[Service] -Type=forking -ExecStart=/usr/sbin/vtund -s - -[Install] -WantedBy=multi-user.target From e9e197c5fb5c54f2d8ab58659974d798f3e99610 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 10 Sep 2011 10:02:52 -0400 Subject: [PATCH 12/54] update support for systemd (#737195) attempt #2 --- vtun.spec | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/vtun.spec b/vtun.spec index 86d2d5d..4d4c20a 100644 --- a/vtun.spec +++ b/vtun.spec @@ -57,14 +57,17 @@ fi if [ $1 -eq 0 ]; then /sbin/service vtund stop >/dev/null 2>&1 || : /sbin/chkconfig --del vtund || : - /bin/systemctl disable vtund.service >/dev/null 2>&1 || : - /bin/systemctl stop vtund.service >/dev/null 2>&1 || : + /bin/systemctl disable vtun.socket >/dev/null 2>&1 || : + /bin/systemctl stop vtun.socket >/dev/null 2>&1 || : + /bin/systemctl disable vtun.service >/dev/null 2>&1 || : + /bin/systemctl stop vtun.service >/dev/null 2>&1 || : fi %postun if [ $1 -eq 1 ]; then /sbin/service vtund condrestart >/dev/null 2>&1 || : - /bin/systemctl try-restart vtund.service >/dev/null 2>&1 || : + /bin/systemctl try-restart vtun.socket >/dev/null 2>&1 || : + /bin/systemctl try-restart vtun.service >/dev/null 2>&1 || : fi %files @@ -73,7 +76,8 @@ fi %config(noreplace) %{_sysconfdir}/vtund.conf %config(noreplace) %{_sysconfdir}/xinetd.d/vtun %{_initrddir}/vtund -/lib/systemd/system/vtund.service +/lib/systemd/system/vtun.socket +/lib/systemd/system/vtun.service %{_sbindir}/vtund %dir %{_localstatedir}/log/vtund %ghost %dir %{_localstatedir}/lock/vtund From 1cc0a9b399f3eda8974f2619428c55ac75acdee2 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 10 Sep 2011 18:07:07 -0400 Subject: [PATCH 13/54] removed xinetd and sysvinit support --- vtun.spec | 27 +++++-------- vtund.init | 110 ----------------------------------------------------- 2 files changed, 9 insertions(+), 128 deletions(-) delete mode 100644 vtund.init diff --git a/vtun.spec b/vtun.spec index 4d4c20a..2b0e37b 100644 --- a/vtun.spec +++ b/vtun.spec @@ -6,13 +6,9 @@ License: GPLv2+ Group: System Environment/Daemons Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz -Source1: vtund.init -Source2: vtun.socket -Source3: vtun.service +Source1: vtun.socket +Source2: vtun.service BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -Requires: xinetd -Requires(post): /sbin/chkconfig -Requires(preun): /sbin/chkconfig Requires(preun): /sbin/service Requires(preun): systemd-units Requires(postun): /sbin/service @@ -38,11 +34,8 @@ require modification to any kernel parts. %install %{__rm} -rf %{buildroot} -%{__install} -D -m 0755 -p %{SOURCE1} %{buildroot}/%{_initrddir}/vtund -%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.socket +%{__install} -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket %{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service -%{__install} -D -m 0644 -p scripts/vtund.xinetd %{buildroot}/%{_sysconfdir}/xinetd.d/vtun -%{__sed} -i 's:/usr/local:%{_prefix}:' %{buildroot}/%{_sysconfdir}/xinetd.d/vtun %{__make} install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %clean @@ -50,22 +43,19 @@ require modification to any kernel parts. %post if [ $1 -eq 1 ]; then - /sbin/chkconfig --add vtund || : + /bin/systemctl daemon-reload >/dev/null 2>&1 || : fi %preun if [ $1 -eq 0 ]; then - /sbin/service vtund stop >/dev/null 2>&1 || : - /sbin/chkconfig --del vtund || : - /bin/systemctl disable vtun.socket >/dev/null 2>&1 || : + /bin/systemctl --no-reload disable vtun.socket >/dev/null 2>&1 || : + /bin/systemctl --no-reload disable vtun.service >/dev/null 2>&1 || : /bin/systemctl stop vtun.socket >/dev/null 2>&1 || : - /bin/systemctl disable vtun.service >/dev/null 2>&1 || : /bin/systemctl stop vtun.service >/dev/null 2>&1 || : fi %postun if [ $1 -eq 1 ]; then - /sbin/service vtund condrestart >/dev/null 2>&1 || : /bin/systemctl try-restart vtun.socket >/dev/null 2>&1 || : /bin/systemctl try-restart vtun.service >/dev/null 2>&1 || : fi @@ -74,8 +64,6 @@ fi %defattr(-,root,root,-) %doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf %config(noreplace) %{_sysconfdir}/vtund.conf -%config(noreplace) %{_sysconfdir}/xinetd.d/vtun -%{_initrddir}/vtund /lib/systemd/system/vtun.socket /lib/systemd/system/vtun.service %{_sbindir}/vtund @@ -86,6 +74,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sat Sep 10 2011 Gabriel Somlo 3.0.1-12 +- removed xinetd and sysvinit support + * Sat Sep 10 2011 Gabriel Somlo 3.0.1-11 - update support for systemd (#737195) diff --git a/vtund.init b/vtund.init deleted file mode 100644 index 13f22bc..0000000 --- a/vtund.init +++ /dev/null @@ -1,110 +0,0 @@ -#!/bin/sh -# -# vtund Startup script for the virtual tunnel daemon -# -# chkconfig: - 55 45 -# description: Virtual Tunnel Daemon provides the facility to create \ -# virtual tunnels over TCP/IP networks and allows for \ -# shaping, compression, and encryption of tunneled traffic. - -### BEGIN INIT INFO -# Provides: -# Required-Start: -# Required-Stop: -# Should-Start: -# Should-Stop: -# Default-Start: -# Default-Stop: -# Short-Description: -# Description: -### END INIT INFO - -# Source function library. -. /etc/rc.d/init.d/functions - -exec="/usr/sbin/vtund" -prog="vtund" -config="/etc/vtund.conf" - -[ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog - -lockfile=/var/lock/subsys/$prog - -start() { - [ -x $exec ] || exit 5 - [ -f $config ] || exit 6 - echo -n $"Starting $prog: " - daemon $exec -s - retval=$? - echo - [ $retval -eq 0 ] && touch $lockfile - return $retval -} - -stop() { - echo -n $"Stopping $prog: " - killproc $prog - retval=$? - echo - [ $retval -eq 0 ] && rm -f $lockfile - return $retval -} - -restart() { - stop - start -} - -reload() { - echo -n $"Reloading config for $prog: " - killproc $prog -HUP - retval=$? - echo - return $retval -} - -force_reload() { - restart -} - -rh_status() { - # run checks to determine if the service is running or use generic status - status $prog -} - -rh_status_q() { - rh_status >/dev/null 2>&1 -} - - -case "$1" in - start) - rh_status_q && exit 0 - $1 - ;; - stop) - rh_status_q || exit 0 - $1 - ;; - restart) - $1 - ;; - reload) - rh_status_q || exit 7 - $1 - ;; - force-reload) - force_reload - ;; - status) - rh_status - ;; - condrestart|try-restart) - rh_status_q || exit 0 - restart - ;; - *) - echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload}" - exit 2 -esac -exit $? From 12ebc6878089b4a5be60d3424435eb1d83599949 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 10 Sep 2011 18:09:40 -0400 Subject: [PATCH 14/54] update release # --- vtun.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 2b0e37b..1821e3c 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 11%{?dist} +Release: 12%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons From b6d68f70e89599a10bb6a4fb357e3bb8f2500c56 Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 14 Jan 2012 02:06:15 -0600 Subject: [PATCH 15/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 1821e3c..e675396 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 12%{?dist} +Release: 13%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -74,6 +74,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sat Jan 14 2012 Fedora Release Engineering - 3.0.1-13 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + * Sat Sep 10 2011 Gabriel Somlo 3.0.1-12 - removed xinetd and sysvinit support From c8ccdd92b17491ef52b6f66377f88b7b07baf8ad Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mon, 21 May 2012 20:42:25 +0100 Subject: [PATCH 16/54] Fix unit file location, cleanup and modernise spec --- vtun.spec | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/vtun.spec b/vtun.spec index e675396..cf572ce 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 13%{?dist} +Release: 14%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -8,10 +8,8 @@ Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtun.socket Source2: vtun.service -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) -Requires(preun): /sbin/service + Requires(preun): systemd-units -Requires(postun): /sbin/service Requires(postun): systemd-units BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units @@ -30,16 +28,12 @@ require modification to any kernel parts. %build %configure -%{__make} %{?_smp_mflags} +make %{?_smp_mflags} %install -%{__rm} -rf %{buildroot} -%{__install} -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket -%{__install} -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service -%{__make} install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" - -%clean -%{__rm} -rf %{buildroot} +install -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket +install -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service +make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %post if [ $1 -eq 1 ]; then @@ -64,8 +58,8 @@ fi %defattr(-,root,root,-) %doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf %config(noreplace) %{_sysconfdir}/vtund.conf -/lib/systemd/system/vtun.socket -/lib/systemd/system/vtun.service +%{_unitdir}/vtun.socket +%{_unitdir}/vtun.service %{_sbindir}/vtund %dir %{_localstatedir}/log/vtund %ghost %dir %{_localstatedir}/lock/vtund @@ -74,6 +68,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Mon May 21 2012 Peter Robinson - 3.0.1-14 +- Fix unit file location, cleanup and modernise spec + * Sat Jan 14 2012 Fedora Release Engineering - 3.0.1-13 - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild From 734c174a9d73c6582dd22149a203f46dbbde300b Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 21 Jul 2012 22:06:39 -0500 Subject: [PATCH 17/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index cf572ce..e917e32 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.1 -Release: 14%{?dist} +Release: 15%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -68,6 +68,9 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Sun Jul 22 2012 Fedora Release Engineering - 3.0.1-15 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + * Mon May 21 2012 Peter Robinson - 3.0.1-14 - Fix unit file location, cleanup and modernise spec From 0194da417f573a2f593efaffcd623d18a6cc1338 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Thu, 13 Sep 2012 10:50:56 -0400 Subject: [PATCH 18/54] update to 3.0.3; new systemd-rpm macros (#850362) --- .gitignore | 1 + sources | 2 +- vtun.spec | 25 ++++++++++--------------- 3 files changed, 12 insertions(+), 16 deletions(-) diff --git a/.gitignore b/.gitignore index 78cf322..f9c375d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ vtun-3.0.1.tar.gz /vtun-3.0.1.tar.gz +/vtun-3.0.3.tar.gz diff --git a/sources b/sources index 6c68109..d62f2f2 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -c342ffe77055d4248a38f0b380f28c1b vtun-3.0.1.tar.gz +f3becf2a0270910a841060c08d1db824 vtun-3.0.3.tar.gz diff --git a/vtun.spec b/vtun.spec index e917e32..a4616af 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun -Version: 3.0.1 -Release: 15%{?dist} +Version: 3.0.3 +Release: 1%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -9,6 +9,7 @@ Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtun.socket Source2: vtun.service +Requires(post): systemd-units Requires(preun): systemd-units Requires(postun): systemd-units BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units @@ -36,23 +37,13 @@ install -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %post -if [ $1 -eq 1 ]; then - /bin/systemctl daemon-reload >/dev/null 2>&1 || : -fi +%systemd_post vtun.service vtun.socket %preun -if [ $1 -eq 0 ]; then - /bin/systemctl --no-reload disable vtun.socket >/dev/null 2>&1 || : - /bin/systemctl --no-reload disable vtun.service >/dev/null 2>&1 || : - /bin/systemctl stop vtun.socket >/dev/null 2>&1 || : - /bin/systemctl stop vtun.service >/dev/null 2>&1 || : -fi +%systemd_preun vtun.service vtun.socket %postun -if [ $1 -eq 1 ]; then - /bin/systemctl try-restart vtun.socket >/dev/null 2>&1 || : - /bin/systemctl try-restart vtun.service >/dev/null 2>&1 || : -fi +%systemd_postun vtun.service vtun.socket %files %defattr(-,root,root,-) @@ -68,6 +59,10 @@ fi %{_mandir}/man8/vtund.8* %changelog +* Thu Sep 13 2012 Gabriel Somlo 3.0.3-1 +- update to 3.0.3 +- new systemd-rpm macros (#850362) + * Sun Jul 22 2012 Fedora Release Engineering - 3.0.1-15 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild From 4520a2ee1dbbf14360f47912229a9c3487a01eb1 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sun, 16 Sep 2012 10:56:40 -0400 Subject: [PATCH 19/54] avoid stripping too early to preserve debuginfo (#857716) --- vtun.spec | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index a4616af..ba51fc2 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -8,6 +8,7 @@ Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtun.socket Source2: vtun.service +Patch0: vtun-nostrip.patch Requires(post): systemd-units Requires(preun): systemd-units @@ -26,6 +27,7 @@ require modification to any kernel parts. %prep %setup -q +%patch0 -p1 %build %configure @@ -59,6 +61,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Sun Sep 16 2012 Gabriel Somlo 3.0.3-2 +- avoid stripping too early to preserve debuginfo (#857716) + * Thu Sep 13 2012 Gabriel Somlo 3.0.3-1 - update to 3.0.3 - new systemd-rpm macros (#850362) From 4da605e27f6ccfd42775d0733a29b2028ff9223c Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sun, 16 Sep 2012 11:01:48 -0400 Subject: [PATCH 20/54] avoid stripping too early to preserve debuginfo (#857716), take 2 --- vtun-nostrip.patch | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 vtun-nostrip.patch diff --git a/vtun-nostrip.patch b/vtun-nostrip.patch new file mode 100644 index 0000000..fb4aa65 --- /dev/null +++ b/vtun-nostrip.patch @@ -0,0 +1,10 @@ +diff -up vtun-3.0.3/Makefile.in~ vtun-3.0.3/Makefile.in +--- vtun-3.0.3/Makefile.in~ 2012-07-09 07:55:38.000000000 +0300 ++++ vtun-3.0.3/Makefile.in 2012-09-16 16:12:41.176283091 +0300 +@@ -99,6 +99,5 @@ install: vtund install_config install_ma + $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(LOCK_DIR) + $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(SBIN_DIR) + $(INSTALL) -m 755 $(INSTALL_OWNER) vtund $(DESTDIR)$(SBIN_DIR) +- $(BIN_DIR)/strip $(DESTDIR)$(SBIN_DIR)/vtund + + # DO NOT DELETE THIS LINE -- make depend depends on it. From fe5b51eb26d7ac78677467949e8104fceecfa97d Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Thu, 14 Feb 2013 20:56:02 -0600 Subject: [PATCH 21/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index ba51fc2..91a05ae 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -61,6 +61,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Fri Feb 15 2013 Fedora Release Engineering - 3.0.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + * Sun Sep 16 2012 Gabriel Somlo 3.0.3-2 - avoid stripping too early to preserve debuginfo (#857716) From 9c5bf51bf9b11dc749b5c66720b1f8ee528e3cf9 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Wed, 1 May 2013 21:32:47 -0400 Subject: [PATCH 22/54] rebuild with PIE (#955286) --- vtun.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index 91a05ae..a66c301 100644 --- a/vtun.spec +++ b/vtun.spec @@ -15,6 +15,9 @@ Requires(preun): systemd-units Requires(postun): systemd-units BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units +#enable PIE/PIC: +%global _hardened_build 1 + %description VTun provides a method for creating Virtual Tunnels over TCP/IP networks and allows one to shape, compress, and encrypt traffic in those tunnels. @@ -61,8 +64,8 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog -* Fri Feb 15 2013 Fedora Release Engineering - 3.0.3-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild +* Wed May 01 2013 Gabriel Somlo 3.0.3-3 +- rebuild with PIE (#955286) * Sun Sep 16 2012 Gabriel Somlo 3.0.3-2 - avoid stripping too early to preserve debuginfo (#857716) From 794bfef1f20f9fb7be0643b73b5c4f2872928d6a Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Wed, 1 May 2013 21:46:53 -0400 Subject: [PATCH 23/54] rebuild with PIE (#955286) --- vtun.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index a66c301..64c276f 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -64,9 +64,12 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog -* Wed May 01 2013 Gabriel Somlo 3.0.3-3 +* Wed May 01 2013 Gabriel Somlo 3.0.3-4 - rebuild with PIE (#955286) +* Fri Feb 15 2013 Fedora Release Engineering +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + * Sun Sep 16 2012 Gabriel Somlo 3.0.3-2 - avoid stripping too early to preserve debuginfo (#857716) From 1a765e55e2e8de11489eef40bca0fecd2354d63e Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Mon, 13 May 2013 10:35:12 -0400 Subject: [PATCH 24/54] added autoconf step to support aarch64 (#926708) --- vtun.spec | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index 64c276f..bf5be37 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -13,7 +13,7 @@ Patch0: vtun-nostrip.patch Requires(post): systemd-units Requires(preun): systemd-units Requires(postun): systemd-units -BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units +BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units autoconf #enable PIE/PIC: %global _hardened_build 1 @@ -33,6 +33,7 @@ require modification to any kernel parts. %patch0 -p1 %build +%{__autoconf} %configure make %{?_smp_mflags} @@ -64,6 +65,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Mon May 13 2013 Gabriel Somlo 2.0.5-5 +- added autoconf step to support aarch64 (#926708) + * Wed May 01 2013 Gabriel Somlo 3.0.3-4 - rebuild with PIE (#955286) From 2cf07ebcdf0a6874405d34e407abbc9145b53c3d Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sun, 4 Aug 2013 01:31:51 -0500 Subject: [PATCH 25/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index bf5be37..31a58ac 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -65,6 +65,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Sun Aug 04 2013 Fedora Release Engineering - 3.0.3-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + * Mon May 13 2013 Gabriel Somlo 2.0.5-5 - added autoconf step to support aarch64 (#926708) From 86d3c3baf510d476047ef69deaa3503e38f3d3b5 Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 7 Jun 2014 23:06:18 -0500 Subject: [PATCH 26/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 31a58ac..082bfd4 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 6%{?dist} +Release: 7%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -65,6 +65,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Sun Jun 08 2014 Fedora Release Engineering - 3.0.3-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + * Sun Aug 04 2013 Fedora Release Engineering - 3.0.3-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild From 17436fe7f3a27224e9c7046ba4ceae86f444a60b Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mon, 18 Aug 2014 08:12:53 +0000 Subject: [PATCH 27/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 082bfd4..fef8ae9 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -65,6 +65,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Mon Aug 18 2014 Fedora Release Engineering - 3.0.3-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + * Sun Jun 08 2014 Fedora Release Engineering - 3.0.3-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild From 44a6fe09a2a54f57489c38db0ef4a87ff4bd7df3 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 15 Nov 2014 23:29:32 -0500 Subject: [PATCH 28/54] added /etc/sysconfig/vtun environment file; updated unit files --- vtun.service | 13 ++++++++++--- vtun.socket | 1 - vtun.spec | 13 ++++++++++--- vtun.sysconfig | 16 ++++++++++++++++ 4 files changed, 36 insertions(+), 7 deletions(-) create mode 100644 vtun.sysconfig diff --git a/vtun.service b/vtun.service index d872e6f..edf21da 100644 --- a/vtun.service +++ b/vtun.service @@ -1,7 +1,14 @@ [Unit] Description=Virtual Tunnels over TCP/IP networks -After=local-fs.target +After=syslog.target network.target [Service] -ExecStart=/usr/sbin/vtund -i -StandardInput=socket +Type=forking +EnvironmentFile=/etc/sysconfig/vtun +ExecStart=/usr/sbin/vtund $OPTIONS +ExecReload=/usr/bin/kill -HUP $MAINPID +KillMode=process +Restart=on-failure + +[Install] +WantedBy=multi-user.target diff --git a/vtun.socket b/vtun.socket index 0dd22f9..07f9d3d 100644 --- a/vtun.socket +++ b/vtun.socket @@ -3,7 +3,6 @@ Description=Vtun Activation Socket [Socket] ListenStream=5000 -Accept=true [Install] WantedBy=sockets.target diff --git a/vtun.spec b/vtun.spec index fef8ae9..38e46ec 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 8%{?dist} +Release: 9%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -8,6 +8,7 @@ Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtun.socket Source2: vtun.service +Source3: vtun.sysconfig Patch0: vtun-nostrip.patch Requires(post): systemd-units @@ -40,6 +41,7 @@ make %{?_smp_mflags} %install install -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket install -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service +install -D -m 0644 -p %{SOURCE3} %{buildroot}/%{_sysconfdir}/sysconfig/vtun make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %post @@ -55,6 +57,7 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %defattr(-,root,root,-) %doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf %config(noreplace) %{_sysconfdir}/vtund.conf +%config(noreplace) %{_sysconfdir}/sysconfig/vtun %{_unitdir}/vtun.socket %{_unitdir}/vtun.service %{_sbindir}/vtund @@ -65,6 +68,10 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Fri Nov 14 2014 Gabriel Somlo 3.0.3-9 +- added /etc/sysconfig/vtun environment file +- updated unit files + * Mon Aug 18 2014 Fedora Release Engineering - 3.0.3-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild @@ -74,7 +81,7 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" * Sun Aug 04 2013 Fedora Release Engineering - 3.0.3-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild -* Mon May 13 2013 Gabriel Somlo 2.0.5-5 +* Mon May 13 2013 Gabriel Somlo 3.0.3-5 - added autoconf step to support aarch64 (#926708) * Wed May 01 2013 Gabriel Somlo 3.0.3-4 @@ -112,7 +119,7 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" - add support for systemd (#661331) * Tue Nov 30 2010 Gabriel Somlo 3.0.1-8 -- using %ghost on /var/lock/vtund directory (#656720) +- using ghost on /var/lock/vtund directory (#656720) * Fri Aug 21 2009 Tomas Mraz - 3.0.1-7 - rebuilt with new openssl diff --git a/vtun.sysconfig b/vtun.sysconfig new file mode 100644 index 0000000..467bd8b --- /dev/null +++ b/vtun.sysconfig @@ -0,0 +1,16 @@ +# Comment out one of the following for client or server mode +# +# To run vtun as a server: +# +#OPTIONS='-s' +# +# +# +#To run vtun as a client, we need: +# +# - session name, e.g. "lion"; must be present in both client and server +# config files. +# +# - server address or host name. +# +#OPTIONS='lion vtun-server.example.com' From 740551ea7f7c48d1cf6f4ffd0af972f0048702d9 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Thu, 20 Nov 2014 17:15:23 -0500 Subject: [PATCH 29/54] enhanced service file (don't daemonize vtund) --- vtun.service | 3 +-- vtun.spec | 5 ++++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/vtun.service b/vtun.service index edf21da..a9e6aca 100644 --- a/vtun.service +++ b/vtun.service @@ -3,9 +3,8 @@ Description=Virtual Tunnels over TCP/IP networks After=syslog.target network.target [Service] -Type=forking EnvironmentFile=/etc/sysconfig/vtun -ExecStart=/usr/sbin/vtund $OPTIONS +ExecStart=/usr/sbin/vtund -n $OPTIONS ExecReload=/usr/bin/kill -HUP $MAINPID KillMode=process Restart=on-failure diff --git a/vtun.spec b/vtun.spec index 38e46ec..a091433 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 9%{?dist} +Release: 10%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -68,6 +68,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Thu Nov 20 2014 Gabriel Somlo 3.0.3-10 +- enhanced service file (-n to prevent daemonizing vtund) + * Fri Nov 14 2014 Gabriel Somlo 3.0.3-9 - added /etc/sysconfig/vtun environment file - updated unit files From ccddc64d074c0ae13856cd8d015b89679166a5d7 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Tue, 23 Dec 2014 00:09:55 -0500 Subject: [PATCH 30/54] enhanced service file (remove "KillMode", use default "cgroup" mode) --- vtun.service | 1 - vtun.spec | 5 ++++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/vtun.service b/vtun.service index a9e6aca..d26d83c 100644 --- a/vtun.service +++ b/vtun.service @@ -6,7 +6,6 @@ After=syslog.target network.target EnvironmentFile=/etc/sysconfig/vtun ExecStart=/usr/sbin/vtund -n $OPTIONS ExecReload=/usr/bin/kill -HUP $MAINPID -KillMode=process Restart=on-failure [Install] diff --git a/vtun.spec b/vtun.spec index a091433..102d8c3 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 10%{?dist} +Release: 11%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -68,6 +68,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Tue Dec 23 2014 Gabriel Somlo 3.0.3-11 +- enhanced service file (remove "KillMode", use default "cgroup" mode) + * Thu Nov 20 2014 Gabriel Somlo 3.0.3-10 - enhanced service file (-n to prevent daemonizing vtund) From c0f984cb7feb7fafdc0cd54defc1197e79c1f5e6 Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Fri, 19 Jun 2015 02:11:12 +0000 Subject: [PATCH 31/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 102d8c3..7b5a4b9 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 11%{?dist} +Release: 12%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -68,6 +68,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Fri Jun 19 2015 Fedora Release Engineering - 3.0.3-12 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + * Tue Dec 23 2014 Gabriel Somlo 3.0.3-11 - enhanced service file (remove "KillMode", use default "cgroup" mode) From eebb079d6d5f99f76388de89f9b711cd1637efc8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ralf=20Cors=C3=A9pius?= Date: Mon, 22 Jun 2015 13:53:17 +0200 Subject: [PATCH 32/54] Append --stdc=gnu89 to CFLAGS (Work-around to c11/inline compatibility issues. Fix FTBFS). --- vtun.spec | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index 7b5a4b9..f3c6489 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 12%{?dist} +Release: 13%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -35,7 +35,10 @@ require modification to any kernel parts. %build %{__autoconf} -%configure +# FIXME: Package suffers from c11/inline issues. +# Workaround by appending --std=gnu89 to CFLAGS +# Proper fix would be to fix the source-code +%configure CFLAGS="${RPM_OPT_FLAGS} --std=gnu89" make %{?_smp_mflags} %install @@ -68,6 +71,10 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Mon Jun 22 2015 Ralf Corsépius - 3.0.3-13 +- Append --stdc=gnu89 to CFLAGS (Work-around to c11/inline compatibility + issues. Fix FTBFS). + * Fri Jun 19 2015 Fedora Release Engineering - 3.0.3-12 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild From e19ff0f94cb25c8ab27a90ffe1e7d545d132e75a Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 5 Feb 2016 02:52:11 +0000 Subject: [PATCH 33/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index f3c6489..4af910a 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 13%{?dist} +Release: 14%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -71,6 +71,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Fri Feb 05 2016 Fedora Release Engineering - 3.0.3-14 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + * Mon Jun 22 2015 Ralf Corsépius - 3.0.3-13 - Append --stdc=gnu89 to CFLAGS (Work-around to c11/inline compatibility issues. Fix FTBFS). From 95e451ea73dc2ae865178b7dda470f6d4cce7678 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Mon, 21 Mar 2016 17:45:07 -0400 Subject: [PATCH 34/54] patch to fix RHBZ 1319858, 1319859 --- vtun-client-sighup.patch | 33 +++++++++++++++++++++++++++++++++ vtun.spec | 7 ++++++- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 vtun-client-sighup.patch diff --git a/vtun-client-sighup.patch b/vtun-client-sighup.patch new file mode 100644 index 0000000..c67bc91 --- /dev/null +++ b/vtun-client-sighup.patch @@ -0,0 +1,33 @@ +When sending a SIGHUP to a vtun client process which is unable to connect +to the remote server, it will attempt to reconnect without sleeping between +consecutive attempts. This results in a CPU usage spike, and a flood of +data sent to syslog. +This patch causes the first sleep after SIGHUP to be discarded, then allows +sleep to be used again in subsequent iterations. +diff -NarU5 a/client.c b/client.c +--- a/client.c 2012-07-08 01:32:57.000000000 -0400 ++++ b/client.c 2016-03-21 17:17:34.111775616 -0400 +@@ -131,10 +131,11 @@ + + if( connect_t(s,(struct sockaddr *) &svr_addr, host->timeout) ){ + if (!vtun.quiet || errno != ETIMEDOUT) + vtun_syslog(LOG_INFO,"Connect to %s failed. %s(%d)", vtun.svr_name, + strerror(errno), errno); ++ client_term = 0; + } else { + if( auth_client(s, host) ){ + vtun_syslog(LOG_INFO,"Session %s[%s] opened",host->host,vtun.svr_name); + + host->rmt_fd = s; +@@ -143,10 +144,11 @@ + client_term = tunnel(host); + + vtun_syslog(LOG_INFO,"Session %s[%s] closed",host->host,vtun.svr_name); + } else { + vtun_syslog(LOG_INFO,"Connection denied by %s",vtun.svr_name); ++ client_term = 0; + } + } + close(s); + free_sopt(&host->sopt); + } diff --git a/vtun.spec b/vtun.spec index 4af910a..cbda083 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 14%{?dist} +Release: 15%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -10,6 +10,7 @@ Source1: vtun.socket Source2: vtun.service Source3: vtun.sysconfig Patch0: vtun-nostrip.patch +Patch1: vtun-client-sighup.patch Requires(post): systemd-units Requires(preun): systemd-units @@ -32,6 +33,7 @@ require modification to any kernel parts. %prep %setup -q %patch0 -p1 +%patch1 -p1 %build %{__autoconf} @@ -71,6 +73,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Mon Mar 21 2016 Gabriel Somlo 3.0.3-15 +- patch to fix #1319858,#1319859,#1319861 + * Fri Feb 05 2016 Fedora Release Engineering - 3.0.3-14 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild From 98ee663d07898489c556981606972c5dc6a7b30b Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 11 Feb 2017 17:13:18 +0000 Subject: [PATCH 35/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index cbda083..bb1ac44 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.3 -Release: 15%{?dist} +Release: 16%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -73,6 +73,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Sat Feb 11 2017 Fedora Release Engineering - 3.0.3-16 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + * Mon Mar 21 2016 Gabriel Somlo 3.0.3-15 - patch to fix #1319858,#1319859,#1319861 From 83ee6d9c2f1483da2e72cf52c7494fe95989a1ed Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Mon, 20 Mar 2017 09:04:14 -0400 Subject: [PATCH 36/54] update to 3.0.4; fix openssl-1.1 build (BZ1424526) --- vtun-client-sighup.patch | 33 ----- vtun-nostrip.patch | 10 +- vtun-openssl.patch | 287 +++++++++++++++++++++++++++++++++++++++ vtun.spec | 10 +- 4 files changed, 300 insertions(+), 40 deletions(-) delete mode 100644 vtun-client-sighup.patch create mode 100644 vtun-openssl.patch diff --git a/vtun-client-sighup.patch b/vtun-client-sighup.patch deleted file mode 100644 index c67bc91..0000000 --- a/vtun-client-sighup.patch +++ /dev/null @@ -1,33 +0,0 @@ -When sending a SIGHUP to a vtun client process which is unable to connect -to the remote server, it will attempt to reconnect without sleeping between -consecutive attempts. This results in a CPU usage spike, and a flood of -data sent to syslog. -This patch causes the first sleep after SIGHUP to be discarded, then allows -sleep to be used again in subsequent iterations. -diff -NarU5 a/client.c b/client.c ---- a/client.c 2012-07-08 01:32:57.000000000 -0400 -+++ b/client.c 2016-03-21 17:17:34.111775616 -0400 -@@ -131,10 +131,11 @@ - - if( connect_t(s,(struct sockaddr *) &svr_addr, host->timeout) ){ - if (!vtun.quiet || errno != ETIMEDOUT) - vtun_syslog(LOG_INFO,"Connect to %s failed. %s(%d)", vtun.svr_name, - strerror(errno), errno); -+ client_term = 0; - } else { - if( auth_client(s, host) ){ - vtun_syslog(LOG_INFO,"Session %s[%s] opened",host->host,vtun.svr_name); - - host->rmt_fd = s; -@@ -143,10 +144,11 @@ - client_term = tunnel(host); - - vtun_syslog(LOG_INFO,"Session %s[%s] closed",host->host,vtun.svr_name); - } else { - vtun_syslog(LOG_INFO,"Connection denied by %s",vtun.svr_name); -+ client_term = 0; - } - } - close(s); - free_sopt(&host->sopt); - } diff --git a/vtun-nostrip.patch b/vtun-nostrip.patch index fb4aa65..cd07a1a 100644 --- a/vtun-nostrip.patch +++ b/vtun-nostrip.patch @@ -1,7 +1,9 @@ -diff -up vtun-3.0.3/Makefile.in~ vtun-3.0.3/Makefile.in ---- vtun-3.0.3/Makefile.in~ 2012-07-09 07:55:38.000000000 +0300 -+++ vtun-3.0.3/Makefile.in 2012-09-16 16:12:41.176283091 +0300 -@@ -99,6 +99,5 @@ install: vtund install_config install_ma +diff -NarU5 a/Makefile.in b/Makefile.in +--- a/Makefile.in 2016-10-01 17:46:00.000000000 -0400 ++++ b/Makefile.in 2017-03-17 16:49:16.195772745 -0400 +@@ -97,8 +97,7 @@ + $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(VAR_DIR)/run + $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(STAT_DIR) $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(LOCK_DIR) $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(SBIN_DIR) $(INSTALL) -m 755 $(INSTALL_OWNER) vtund $(DESTDIR)$(SBIN_DIR) diff --git a/vtun-openssl.patch b/vtun-openssl.patch new file mode 100644 index 0000000..c375789 --- /dev/null +++ b/vtun-openssl.patch @@ -0,0 +1,287 @@ +diff -NarU5 a/lfd_encrypt.c b/lfd_encrypt.c +--- a/lfd_encrypt.c 2016-10-01 17:27:51.000000000 -0400 ++++ b/lfd_encrypt.c 2017-03-20 08:43:48.013308435 -0400 +@@ -93,15 +93,15 @@ + static int dec_init_first_time; + static unsigned long sequence_num; + static char * pkey; + static char * iv_buf; + +-static EVP_CIPHER_CTX ctx_enc; /* encrypt */ +-static EVP_CIPHER_CTX ctx_dec; /* decrypt */ ++static EVP_CIPHER_CTX *ctx_enc; /* encrypt */ ++static EVP_CIPHER_CTX *ctx_dec; /* decrypt */ + +-static EVP_CIPHER_CTX ctx_enc_ecb; /* sideband ecb encrypt */ +-static EVP_CIPHER_CTX ctx_dec_ecb; /* sideband ecb decrypt */ ++static EVP_CIPHER_CTX *ctx_enc_ecb; /* sideband ecb encrypt */ ++static EVP_CIPHER_CTX *ctx_dec_ecb; /* sideband ecb decrypt */ + + static int send_msg(int len, char *in, char **out); + static int recv_msg(int len, char *in, char **out); + static int send_ib_mesg(int *len, char **in); + static int recv_ib_mesg(int *len, char **in); +@@ -180,37 +180,37 @@ + case VTUN_ENC_AES256CBC: + blocksize = 16; + keysize = 32; + sb_init = 1; + cipher_type = EVP_aes_256_ecb(); +- pctx_enc = &ctx_enc_ecb; +- pctx_dec = &ctx_dec_ecb; ++ pctx_enc = ctx_enc_ecb; ++ pctx_dec = ctx_dec_ecb; + break; + + case VTUN_ENC_AES256ECB: + blocksize = 16; + keysize = 32; +- pctx_enc = &ctx_enc; +- pctx_dec = &ctx_dec; ++ pctx_enc = ctx_enc; ++ pctx_dec = ctx_dec; + cipher_type = EVP_aes_256_ecb(); + strcpy(cipher_name,"AES-256-ECB"); + break; + case VTUN_ENC_AES128OFB: + case VTUN_ENC_AES128CFB: + case VTUN_ENC_AES128CBC: + blocksize = 16; + keysize = 16; + sb_init=1; + cipher_type = EVP_aes_128_ecb(); +- pctx_enc = &ctx_enc_ecb; +- pctx_dec = &ctx_dec_ecb; ++ pctx_enc = ctx_enc_ecb; ++ pctx_dec = ctx_dec_ecb; + break; + case VTUN_ENC_AES128ECB: + blocksize = 16; + keysize = 16; +- pctx_enc = &ctx_enc; +- pctx_dec = &ctx_dec; ++ pctx_enc = ctx_enc; ++ pctx_dec = ctx_dec; + cipher_type = EVP_aes_128_ecb(); + strcpy(cipher_name,"AES-128-ECB"); + break; + + case VTUN_ENC_BF256OFB: +@@ -219,20 +219,20 @@ + blocksize = 8; + keysize = 32; + var_key = 1; + sb_init = 1; + cipher_type = EVP_bf_ecb(); +- pctx_enc = &ctx_enc_ecb; +- pctx_dec = &ctx_dec_ecb; ++ pctx_enc = ctx_enc_ecb; ++ pctx_dec = ctx_dec_ecb; + break; + + case VTUN_ENC_BF256ECB: + blocksize = 8; + keysize = 32; + var_key = 1; +- pctx_enc = &ctx_enc; +- pctx_dec = &ctx_dec; ++ pctx_enc = ctx_enc; ++ pctx_dec = ctx_dec; + cipher_type = EVP_bf_ecb(); + strcpy(cipher_name,"Blowfish-256-ECB"); + break; + + case VTUN_ENC_BF128OFB: +@@ -241,26 +241,28 @@ + blocksize = 8; + keysize = 16; + var_key = 1; + sb_init = 1; + cipher_type = EVP_bf_ecb(); +- pctx_enc = &ctx_enc_ecb; +- pctx_dec = &ctx_dec_ecb; ++ pctx_enc = ctx_enc_ecb; ++ pctx_dec = ctx_dec_ecb; + break; + case VTUN_ENC_BF128ECB: /* blowfish 128 ecb is the default */ + default: + blocksize = 8; + keysize = 16; + var_key = 1; +- pctx_enc = &ctx_enc; +- pctx_dec = &ctx_dec; ++ pctx_enc = ctx_enc; ++ pctx_dec = ctx_dec; + cipher_type = EVP_bf_ecb(); + strcpy(cipher_name,"Blowfish-128-ECB"); + break; + } /* switch(host->cipher) */ + + if (prep_key(&pkey, keysize, host) != 0) return -1; ++ pctx_enc = EVP_CIPHER_CTX_new(); ++ pctx_dec = EVP_CIPHER_CTX_new(); + EVP_CIPHER_CTX_init(pctx_enc); + EVP_CIPHER_CTX_init(pctx_dec); + EVP_EncryptInit_ex(pctx_enc, cipher_type, NULL, NULL, NULL); + EVP_DecryptInit_ex(pctx_dec, cipher_type, NULL, NULL, NULL); + if (var_key) +@@ -292,14 +294,14 @@ + free_key(pkey); pkey = NULL; + + lfd_free(enc_buf); enc_buf = NULL; + lfd_free(dec_buf); dec_buf = NULL; + +- EVP_CIPHER_CTX_cleanup(&ctx_enc); +- EVP_CIPHER_CTX_cleanup(&ctx_dec); +- EVP_CIPHER_CTX_cleanup(&ctx_enc_ecb); +- EVP_CIPHER_CTX_cleanup(&ctx_dec_ecb); ++ EVP_CIPHER_CTX_free(ctx_enc); ++ EVP_CIPHER_CTX_free(ctx_dec); ++ EVP_CIPHER_CTX_free(ctx_enc_ecb); ++ EVP_CIPHER_CTX_free(ctx_dec_ecb); + + return 0; + } + + static int encrypt_buf(int len, char *in, char **out) +@@ -321,11 +323,11 @@ + + memset(in_ptr+len, pad, pad); + outlen=len+pad; + if (pad == blocksize) + RAND_bytes(in_ptr+len, blocksize-1); +- EVP_EncryptUpdate(&ctx_enc, out_ptr, &outlen, in_ptr, len+pad); ++ EVP_EncryptUpdate(ctx_enc, out_ptr, &outlen, in_ptr, len+pad); + *out = enc_buf; + + sequence_num++; + + return outlen+msg_len; +@@ -341,11 +343,11 @@ + in = *out; + in_ptr = in; + + outlen=len; + if (!len) return 0; +- EVP_DecryptUpdate(&ctx_dec, out_ptr, &outlen, in_ptr, len); ++ EVP_DecryptUpdate(ctx_dec, out_ptr, &outlen, in_ptr, len); + recv_ib_mesg(&outlen, &out_ptr); + if (!outlen) return 0; + tmp_ptr = out_ptr + outlen; tmp_ptr--; + pad = *tmp_ptr; + if (pad < 1 || pad > blocksize) { +@@ -429,17 +431,18 @@ + /* if we're here, something weird's going on */ + return -1; + break; + } /* switch(cipher) */ + +- EVP_CIPHER_CTX_init(&ctx_enc); +- EVP_EncryptInit_ex(&ctx_enc, cipher_type, NULL, NULL, NULL); ++ ctx_enc = EVP_CIPHER_CTX_new(); ++ EVP_CIPHER_CTX_init(ctx_enc); ++ EVP_EncryptInit_ex(ctx_enc, cipher_type, NULL, NULL, NULL); + if (var_key) +- EVP_CIPHER_CTX_set_key_length(&ctx_enc, keysize); +- EVP_EncryptInit_ex(&ctx_enc, NULL, NULL, pkey, NULL); +- EVP_EncryptInit_ex(&ctx_enc, NULL, NULL, NULL, iv); +- EVP_CIPHER_CTX_set_padding(&ctx_enc, 0); ++ EVP_CIPHER_CTX_set_key_length(ctx_enc, keysize); ++ EVP_EncryptInit_ex(ctx_enc, NULL, NULL, pkey, NULL); ++ EVP_EncryptInit_ex(ctx_enc, NULL, NULL, NULL, iv); ++ EVP_CIPHER_CTX_set_padding(ctx_enc, 0); + if (enc_init_first_time) + { + sprintf(tmpstr,"%s encryption initialized", cipher_name); + vtun_syslog(LOG_INFO, tmpstr); + enc_init_first_time = 0; +@@ -519,17 +522,18 @@ + /* if we're here, something weird's going on */ + return -1; + break; + } /* switch(cipher) */ + +- EVP_CIPHER_CTX_init(&ctx_dec); +- EVP_DecryptInit_ex(&ctx_dec, cipher_type, NULL, NULL, NULL); ++ ctx_dec = EVP_CIPHER_CTX_new(); ++ EVP_CIPHER_CTX_init(ctx_dec); ++ EVP_DecryptInit_ex(ctx_dec, cipher_type, NULL, NULL, NULL); + if (var_key) +- EVP_CIPHER_CTX_set_key_length(&ctx_dec, keysize); +- EVP_DecryptInit_ex(&ctx_dec, NULL, NULL, pkey, NULL); +- EVP_DecryptInit_ex(&ctx_dec, NULL, NULL, NULL, iv); +- EVP_CIPHER_CTX_set_padding(&ctx_dec, 0); ++ EVP_CIPHER_CTX_set_key_length(ctx_dec, keysize); ++ EVP_DecryptInit_ex(ctx_dec, NULL, NULL, pkey, NULL); ++ EVP_DecryptInit_ex(ctx_dec, NULL, NULL, NULL, iv); ++ EVP_CIPHER_CTX_set_padding(ctx_dec, 0); + if (dec_init_first_time) + { + sprintf(tmpstr,"%s decryption initialized", cipher_name); + vtun_syslog(LOG_INFO, tmpstr); + dec_init_first_time = 0; +@@ -557,11 +561,11 @@ + memset(iv,0,blocksize); free(iv); iv = NULL; + RAND_bytes(in_ptr, in - in_ptr); + + in_ptr = in - blocksize*2; + outlen = blocksize*2; +- EVP_EncryptUpdate(&ctx_enc_ecb, in_ptr, ++ EVP_EncryptUpdate(ctx_enc_ecb, in_ptr, + &outlen, in_ptr, blocksize*2); + *out = in_ptr; + len = outlen; + cipher_enc_state = CIPHER_SEQUENCE; + break; +@@ -584,11 +588,11 @@ + { + case CIPHER_INIT: + in_ptr = in; + iv = malloc(blocksize); + outlen = blocksize*2; +- EVP_DecryptUpdate(&ctx_dec_ecb, in_ptr, &outlen, in_ptr, blocksize*2); ++ EVP_DecryptUpdate(ctx_dec_ecb, in_ptr, &outlen, in_ptr, blocksize*2); + + if ( !strncmp(in_ptr, "ivec", 4) ) + { + memcpy(iv, in_ptr+4, blocksize); + cipher_dec_init(iv); +@@ -627,11 +631,11 @@ + "Max. gibberish threshold reached"); + #endif + if (cipher_enc_state != CIPHER_INIT) + { + cipher_enc_state = CIPHER_INIT; +- EVP_CIPHER_CTX_cleanup(&ctx_enc); ++ EVP_CIPHER_CTX_free(ctx_enc); + #ifdef LFD_ENCRYPT_DEBUG + vtun_syslog(LOG_INFO, + "Forcing local encryptor re-init"); + #endif + } +@@ -708,11 +712,11 @@ + *len -= blocksize; + + if (cipher_enc_state != CIPHER_INIT) + { + cipher_enc_state = CIPHER_INIT; +- EVP_CIPHER_CTX_cleanup(&ctx_enc); ++ EVP_CIPHER_CTX_free(ctx_enc); + } + #ifdef LFD_ENCRYPT_DEBUG + vtun_syslog(LOG_INFO, "Remote requests encryptor re-init"); + #endif + } +@@ -722,11 +726,11 @@ + + if (cipher_dec_state != CIPHER_INIT && + cipher_enc_state != CIPHER_REQ_INIT && + cipher_enc_state != CIPHER_INIT) + { +- EVP_CIPHER_CTX_cleanup (&ctx_dec); ++ EVP_CIPHER_CTX_free (ctx_dec); + cipher_dec_state = CIPHER_INIT; + cipher_enc_state = CIPHER_REQ_INIT; + } + #ifdef LFD_ENCRYPT_DEBUG + vtun_syslog(LOG_INFO, "Local decryptor out of sync"); diff --git a/vtun.spec b/vtun.spec index bb1ac44..bbd3c7d 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun -Version: 3.0.3 -Release: 16%{?dist} +Version: 3.0.4 +Release: 1%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -10,7 +10,7 @@ Source1: vtun.socket Source2: vtun.service Source3: vtun.sysconfig Patch0: vtun-nostrip.patch -Patch1: vtun-client-sighup.patch +Patch1: vtun-openssl.patch Requires(post): systemd-units Requires(preun): systemd-units @@ -73,6 +73,10 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Fri Mar 17 2017 Gabriel Somlo 3.0.3-1 +- update to 3.0.4 +- patch for openssl-1.1 transition + * Sat Feb 11 2017 Fedora Release Engineering - 3.0.3-16 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild From 2e411b90b742ddf4df773c089264bb006b75a155 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Wed, 22 Mar 2017 09:10:15 -0400 Subject: [PATCH 37/54] push new vtun sources to lookaside cache --- .gitignore | 1 + sources | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index f9c375d..2711247 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ vtun-3.0.1.tar.gz /vtun-3.0.1.tar.gz /vtun-3.0.3.tar.gz +/vtun-3.0.4.tar.gz diff --git a/sources b/sources index d62f2f2..1487886 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -f3becf2a0270910a841060c08d1db824 vtun-3.0.3.tar.gz +SHA512 (vtun-3.0.4.tar.gz) = b1bb7294bd745c2ca888704e2b0f8e05447b5e01bec0f921648afe363d61a19508dea9e26663993cd69c506aa92621e76f36045bddf7c3723d13a72741ca6781 From 7ab437d6519c26d572e8660f0b71d422e27bfd40 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 27 Jul 2017 21:27:31 +0000 Subject: [PATCH 38/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index bbd3c7d..a32baa9 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -73,6 +73,9 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_mandir}/man8/vtund.8* %changelog +* Thu Jul 27 2017 Fedora Release Engineering - 3.0.4-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + * Fri Mar 17 2017 Gabriel Somlo 3.0.3-1 - update to 3.0.4 - patch for openssl-1.1 transition From 266a063f3a914b83fb4e4a84f50c43d746896696 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Mon, 31 Jul 2017 14:44:47 -0400 Subject: [PATCH 39/54] add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs --- vtun.spec | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/vtun.spec b/vtun.spec index a32baa9..f98c756 100644 --- a/vtun.spec +++ b/vtun.spec @@ -48,6 +48,11 @@ install -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket install -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service install -D -m 0644 -p %{SOURCE3} %{buildroot}/%{_sysconfdir}/sysconfig/vtun make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" +# tmpfiles.d configuration for /var/lock/vtund: +mkdir -p %{buildroot}/%{_tmpfilesdir} +cat > %{buildroot}/%{_tmpfilesdir}/%{name}.conf << EOT +d %{_localstatedir}/lock/vtund 0755 root root - +EOT %post %systemd_post vtun.service vtun.socket @@ -66,15 +71,16 @@ make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" %{_unitdir}/vtun.socket %{_unitdir}/vtun.service %{_sbindir}/vtund +%{_tmpfilesdir}/%{name}.conf %dir %{_localstatedir}/log/vtund -%ghost %dir %{_localstatedir}/lock/vtund +%dir %{_localstatedir}/lock/vtund %{_mandir}/man5/vtund.conf.5* %{_mandir}/man8/vtun.8* %{_mandir}/man8/vtund.8* %changelog -* Thu Jul 27 2017 Fedora Release Engineering - 3.0.4-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild +* Mon Jul 31 2017 Gabriel Somlo 3.0.3-2 +- add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs * Fri Mar 17 2017 Gabriel Somlo 3.0.3-1 - update to 3.0.4 From f4f3570aab41c6a94248b545f08b68815a11213d Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 3 Aug 2017 10:09:58 +0000 Subject: [PATCH 40/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index f98c756..b46e596 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -79,6 +79,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Thu Aug 03 2017 Fedora Release Engineering - 3.0.4-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + * Mon Jul 31 2017 Gabriel Somlo 3.0.3-2 - add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs From 8014407ad0671f92a8da72ff9fddb25b8de173d4 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 2 Sep 2017 18:36:24 -0400 Subject: [PATCH 41/54] apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) --- vtun.spec | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index b46e596..8f135f1 100644 --- a/vtun.spec +++ b/vtun.spec @@ -33,7 +33,9 @@ require modification to any kernel parts. %prep %setup -q %patch0 -p1 +%if 0%{?fedora} >= 26 %patch1 -p1 +%endif %build %{__autoconf} @@ -79,8 +81,8 @@ EOT %{_mandir}/man8/vtund.8* %changelog -* Thu Aug 03 2017 Fedora Release Engineering - 3.0.4-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild +* Sat Sep 02 2017 Gabriel Somlo 3.0.3-3 +- apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) * Mon Jul 31 2017 Gabriel Somlo 3.0.3-2 - add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs From 4fcfb7b37543d862385c49312a29137164be46f1 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Sat, 2 Sep 2017 18:40:57 -0400 Subject: [PATCH 42/54] apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) --- vtun.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vtun.spec b/vtun.spec index 8f135f1..dd77184 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -81,9 +81,12 @@ EOT %{_mandir}/man8/vtund.8* %changelog -* Sat Sep 02 2017 Gabriel Somlo 3.0.3-3 +* Sat Sep 02 2017 Gabriel Somlo 3.0.3-4 - apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) +* Thu Aug 03 2017 Fedora Release Engineering - 3.0.4-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + * Mon Jul 31 2017 Gabriel Somlo 3.0.3-2 - add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs From f288dfa08f289e6f546dc783a05bcf36f6d1c9b2 Mon Sep 17 00:00:00 2001 From: "Gabriel L. Somlo" Date: Wed, 11 Oct 2017 13:56:32 -0400 Subject: [PATCH 43/54] requiring compat-openssl1.0 on >= f26 --- vtun-openssl.patch | 287 --------------------------------------------- vtun.spec | 16 ++- 2 files changed, 10 insertions(+), 293 deletions(-) delete mode 100644 vtun-openssl.patch diff --git a/vtun-openssl.patch b/vtun-openssl.patch deleted file mode 100644 index c375789..0000000 --- a/vtun-openssl.patch +++ /dev/null @@ -1,287 +0,0 @@ -diff -NarU5 a/lfd_encrypt.c b/lfd_encrypt.c ---- a/lfd_encrypt.c 2016-10-01 17:27:51.000000000 -0400 -+++ b/lfd_encrypt.c 2017-03-20 08:43:48.013308435 -0400 -@@ -93,15 +93,15 @@ - static int dec_init_first_time; - static unsigned long sequence_num; - static char * pkey; - static char * iv_buf; - --static EVP_CIPHER_CTX ctx_enc; /* encrypt */ --static EVP_CIPHER_CTX ctx_dec; /* decrypt */ -+static EVP_CIPHER_CTX *ctx_enc; /* encrypt */ -+static EVP_CIPHER_CTX *ctx_dec; /* decrypt */ - --static EVP_CIPHER_CTX ctx_enc_ecb; /* sideband ecb encrypt */ --static EVP_CIPHER_CTX ctx_dec_ecb; /* sideband ecb decrypt */ -+static EVP_CIPHER_CTX *ctx_enc_ecb; /* sideband ecb encrypt */ -+static EVP_CIPHER_CTX *ctx_dec_ecb; /* sideband ecb decrypt */ - - static int send_msg(int len, char *in, char **out); - static int recv_msg(int len, char *in, char **out); - static int send_ib_mesg(int *len, char **in); - static int recv_ib_mesg(int *len, char **in); -@@ -180,37 +180,37 @@ - case VTUN_ENC_AES256CBC: - blocksize = 16; - keysize = 32; - sb_init = 1; - cipher_type = EVP_aes_256_ecb(); -- pctx_enc = &ctx_enc_ecb; -- pctx_dec = &ctx_dec_ecb; -+ pctx_enc = ctx_enc_ecb; -+ pctx_dec = ctx_dec_ecb; - break; - - case VTUN_ENC_AES256ECB: - blocksize = 16; - keysize = 32; -- pctx_enc = &ctx_enc; -- pctx_dec = &ctx_dec; -+ pctx_enc = ctx_enc; -+ pctx_dec = ctx_dec; - cipher_type = EVP_aes_256_ecb(); - strcpy(cipher_name,"AES-256-ECB"); - break; - case VTUN_ENC_AES128OFB: - case VTUN_ENC_AES128CFB: - case VTUN_ENC_AES128CBC: - blocksize = 16; - keysize = 16; - sb_init=1; - cipher_type = EVP_aes_128_ecb(); -- pctx_enc = &ctx_enc_ecb; -- pctx_dec = &ctx_dec_ecb; -+ pctx_enc = ctx_enc_ecb; -+ pctx_dec = ctx_dec_ecb; - break; - case VTUN_ENC_AES128ECB: - blocksize = 16; - keysize = 16; -- pctx_enc = &ctx_enc; -- pctx_dec = &ctx_dec; -+ pctx_enc = ctx_enc; -+ pctx_dec = ctx_dec; - cipher_type = EVP_aes_128_ecb(); - strcpy(cipher_name,"AES-128-ECB"); - break; - - case VTUN_ENC_BF256OFB: -@@ -219,20 +219,20 @@ - blocksize = 8; - keysize = 32; - var_key = 1; - sb_init = 1; - cipher_type = EVP_bf_ecb(); -- pctx_enc = &ctx_enc_ecb; -- pctx_dec = &ctx_dec_ecb; -+ pctx_enc = ctx_enc_ecb; -+ pctx_dec = ctx_dec_ecb; - break; - - case VTUN_ENC_BF256ECB: - blocksize = 8; - keysize = 32; - var_key = 1; -- pctx_enc = &ctx_enc; -- pctx_dec = &ctx_dec; -+ pctx_enc = ctx_enc; -+ pctx_dec = ctx_dec; - cipher_type = EVP_bf_ecb(); - strcpy(cipher_name,"Blowfish-256-ECB"); - break; - - case VTUN_ENC_BF128OFB: -@@ -241,26 +241,28 @@ - blocksize = 8; - keysize = 16; - var_key = 1; - sb_init = 1; - cipher_type = EVP_bf_ecb(); -- pctx_enc = &ctx_enc_ecb; -- pctx_dec = &ctx_dec_ecb; -+ pctx_enc = ctx_enc_ecb; -+ pctx_dec = ctx_dec_ecb; - break; - case VTUN_ENC_BF128ECB: /* blowfish 128 ecb is the default */ - default: - blocksize = 8; - keysize = 16; - var_key = 1; -- pctx_enc = &ctx_enc; -- pctx_dec = &ctx_dec; -+ pctx_enc = ctx_enc; -+ pctx_dec = ctx_dec; - cipher_type = EVP_bf_ecb(); - strcpy(cipher_name,"Blowfish-128-ECB"); - break; - } /* switch(host->cipher) */ - - if (prep_key(&pkey, keysize, host) != 0) return -1; -+ pctx_enc = EVP_CIPHER_CTX_new(); -+ pctx_dec = EVP_CIPHER_CTX_new(); - EVP_CIPHER_CTX_init(pctx_enc); - EVP_CIPHER_CTX_init(pctx_dec); - EVP_EncryptInit_ex(pctx_enc, cipher_type, NULL, NULL, NULL); - EVP_DecryptInit_ex(pctx_dec, cipher_type, NULL, NULL, NULL); - if (var_key) -@@ -292,14 +294,14 @@ - free_key(pkey); pkey = NULL; - - lfd_free(enc_buf); enc_buf = NULL; - lfd_free(dec_buf); dec_buf = NULL; - -- EVP_CIPHER_CTX_cleanup(&ctx_enc); -- EVP_CIPHER_CTX_cleanup(&ctx_dec); -- EVP_CIPHER_CTX_cleanup(&ctx_enc_ecb); -- EVP_CIPHER_CTX_cleanup(&ctx_dec_ecb); -+ EVP_CIPHER_CTX_free(ctx_enc); -+ EVP_CIPHER_CTX_free(ctx_dec); -+ EVP_CIPHER_CTX_free(ctx_enc_ecb); -+ EVP_CIPHER_CTX_free(ctx_dec_ecb); - - return 0; - } - - static int encrypt_buf(int len, char *in, char **out) -@@ -321,11 +323,11 @@ - - memset(in_ptr+len, pad, pad); - outlen=len+pad; - if (pad == blocksize) - RAND_bytes(in_ptr+len, blocksize-1); -- EVP_EncryptUpdate(&ctx_enc, out_ptr, &outlen, in_ptr, len+pad); -+ EVP_EncryptUpdate(ctx_enc, out_ptr, &outlen, in_ptr, len+pad); - *out = enc_buf; - - sequence_num++; - - return outlen+msg_len; -@@ -341,11 +343,11 @@ - in = *out; - in_ptr = in; - - outlen=len; - if (!len) return 0; -- EVP_DecryptUpdate(&ctx_dec, out_ptr, &outlen, in_ptr, len); -+ EVP_DecryptUpdate(ctx_dec, out_ptr, &outlen, in_ptr, len); - recv_ib_mesg(&outlen, &out_ptr); - if (!outlen) return 0; - tmp_ptr = out_ptr + outlen; tmp_ptr--; - pad = *tmp_ptr; - if (pad < 1 || pad > blocksize) { -@@ -429,17 +431,18 @@ - /* if we're here, something weird's going on */ - return -1; - break; - } /* switch(cipher) */ - -- EVP_CIPHER_CTX_init(&ctx_enc); -- EVP_EncryptInit_ex(&ctx_enc, cipher_type, NULL, NULL, NULL); -+ ctx_enc = EVP_CIPHER_CTX_new(); -+ EVP_CIPHER_CTX_init(ctx_enc); -+ EVP_EncryptInit_ex(ctx_enc, cipher_type, NULL, NULL, NULL); - if (var_key) -- EVP_CIPHER_CTX_set_key_length(&ctx_enc, keysize); -- EVP_EncryptInit_ex(&ctx_enc, NULL, NULL, pkey, NULL); -- EVP_EncryptInit_ex(&ctx_enc, NULL, NULL, NULL, iv); -- EVP_CIPHER_CTX_set_padding(&ctx_enc, 0); -+ EVP_CIPHER_CTX_set_key_length(ctx_enc, keysize); -+ EVP_EncryptInit_ex(ctx_enc, NULL, NULL, pkey, NULL); -+ EVP_EncryptInit_ex(ctx_enc, NULL, NULL, NULL, iv); -+ EVP_CIPHER_CTX_set_padding(ctx_enc, 0); - if (enc_init_first_time) - { - sprintf(tmpstr,"%s encryption initialized", cipher_name); - vtun_syslog(LOG_INFO, tmpstr); - enc_init_first_time = 0; -@@ -519,17 +522,18 @@ - /* if we're here, something weird's going on */ - return -1; - break; - } /* switch(cipher) */ - -- EVP_CIPHER_CTX_init(&ctx_dec); -- EVP_DecryptInit_ex(&ctx_dec, cipher_type, NULL, NULL, NULL); -+ ctx_dec = EVP_CIPHER_CTX_new(); -+ EVP_CIPHER_CTX_init(ctx_dec); -+ EVP_DecryptInit_ex(ctx_dec, cipher_type, NULL, NULL, NULL); - if (var_key) -- EVP_CIPHER_CTX_set_key_length(&ctx_dec, keysize); -- EVP_DecryptInit_ex(&ctx_dec, NULL, NULL, pkey, NULL); -- EVP_DecryptInit_ex(&ctx_dec, NULL, NULL, NULL, iv); -- EVP_CIPHER_CTX_set_padding(&ctx_dec, 0); -+ EVP_CIPHER_CTX_set_key_length(ctx_dec, keysize); -+ EVP_DecryptInit_ex(ctx_dec, NULL, NULL, pkey, NULL); -+ EVP_DecryptInit_ex(ctx_dec, NULL, NULL, NULL, iv); -+ EVP_CIPHER_CTX_set_padding(ctx_dec, 0); - if (dec_init_first_time) - { - sprintf(tmpstr,"%s decryption initialized", cipher_name); - vtun_syslog(LOG_INFO, tmpstr); - dec_init_first_time = 0; -@@ -557,11 +561,11 @@ - memset(iv,0,blocksize); free(iv); iv = NULL; - RAND_bytes(in_ptr, in - in_ptr); - - in_ptr = in - blocksize*2; - outlen = blocksize*2; -- EVP_EncryptUpdate(&ctx_enc_ecb, in_ptr, -+ EVP_EncryptUpdate(ctx_enc_ecb, in_ptr, - &outlen, in_ptr, blocksize*2); - *out = in_ptr; - len = outlen; - cipher_enc_state = CIPHER_SEQUENCE; - break; -@@ -584,11 +588,11 @@ - { - case CIPHER_INIT: - in_ptr = in; - iv = malloc(blocksize); - outlen = blocksize*2; -- EVP_DecryptUpdate(&ctx_dec_ecb, in_ptr, &outlen, in_ptr, blocksize*2); -+ EVP_DecryptUpdate(ctx_dec_ecb, in_ptr, &outlen, in_ptr, blocksize*2); - - if ( !strncmp(in_ptr, "ivec", 4) ) - { - memcpy(iv, in_ptr+4, blocksize); - cipher_dec_init(iv); -@@ -627,11 +631,11 @@ - "Max. gibberish threshold reached"); - #endif - if (cipher_enc_state != CIPHER_INIT) - { - cipher_enc_state = CIPHER_INIT; -- EVP_CIPHER_CTX_cleanup(&ctx_enc); -+ EVP_CIPHER_CTX_free(ctx_enc); - #ifdef LFD_ENCRYPT_DEBUG - vtun_syslog(LOG_INFO, - "Forcing local encryptor re-init"); - #endif - } -@@ -708,11 +712,11 @@ - *len -= blocksize; - - if (cipher_enc_state != CIPHER_INIT) - { - cipher_enc_state = CIPHER_INIT; -- EVP_CIPHER_CTX_cleanup(&ctx_enc); -+ EVP_CIPHER_CTX_free(ctx_enc); - } - #ifdef LFD_ENCRYPT_DEBUG - vtun_syslog(LOG_INFO, "Remote requests encryptor re-init"); - #endif - } -@@ -722,11 +726,11 @@ - - if (cipher_dec_state != CIPHER_INIT && - cipher_enc_state != CIPHER_REQ_INIT && - cipher_enc_state != CIPHER_INIT) - { -- EVP_CIPHER_CTX_cleanup (&ctx_dec); -+ EVP_CIPHER_CTX_free (ctx_dec); - cipher_dec_state = CIPHER_INIT; - cipher_enc_state = CIPHER_REQ_INIT; - } - #ifdef LFD_ENCRYPT_DEBUG - vtun_syslog(LOG_INFO, "Local decryptor out of sync"); diff --git a/vtun.spec b/vtun.spec index dd77184..8c642de 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -10,12 +10,16 @@ Source1: vtun.socket Source2: vtun.service Source3: vtun.sysconfig Patch0: vtun-nostrip.patch -Patch1: vtun-openssl.patch Requires(post): systemd-units Requires(preun): systemd-units Requires(postun): systemd-units -BuildRequires: zlib-devel lzo-devel openssl-devel bison flex systemd-units autoconf +BuildRequires: zlib-devel lzo-devel bison flex systemd-units autoconf +%if 0%{?fedora} >= 26 +BuildRequires: compat-openssl10-devel +%else +BuildRequires: openssl-devel +%endif #enable PIE/PIC: %global _hardened_build 1 @@ -33,9 +37,6 @@ require modification to any kernel parts. %prep %setup -q %patch0 -p1 -%if 0%{?fedora} >= 26 -%patch1 -p1 -%endif %build %{__autoconf} @@ -81,6 +82,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Sat Sep 02 2017 Gabriel Somlo 3.0.3-5 +- remove segfaulting openssl-1.1 patch; use compat-openssl10 instead + * Sat Sep 02 2017 Gabriel Somlo 3.0.3-4 - apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) From b51c8f84af78a29f11ff26fc1013820d0abe0cb1 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 9 Feb 2018 20:42:28 +0000 Subject: [PATCH 44/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 8c642de..35506bb 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 5%{?dist} +Release: 6%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -82,6 +82,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Fri Feb 09 2018 Fedora Release Engineering - 3.0.4-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + * Sat Sep 02 2017 Gabriel Somlo 3.0.3-5 - remove segfaulting openssl-1.1 patch; use compat-openssl10 instead From 7f161bf488f1322ba04d9fc8ea5da44fab58b90f Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Mon, 9 Jul 2018 19:06:53 +0200 Subject: [PATCH 45/54] add BuildRequires: gcc Reference: https://fedoraproject.org/wiki/Changes/Remove_GCC_from_BuildRoot --- vtun.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/vtun.spec b/vtun.spec index 35506bb..0f84888 100644 --- a/vtun.spec +++ b/vtun.spec @@ -14,6 +14,7 @@ Patch0: vtun-nostrip.patch Requires(post): systemd-units Requires(preun): systemd-units Requires(postun): systemd-units +BuildRequires: gcc BuildRequires: zlib-devel lzo-devel bison flex systemd-units autoconf %if 0%{?fedora} >= 26 BuildRequires: compat-openssl10-devel From 51f51041d2a0b465c025651b16c47919003e5079 Mon Sep 17 00:00:00 2001 From: Jason Tibbitts Date: Tue, 10 Jul 2018 01:43:57 -0500 Subject: [PATCH 46/54] Remove needless use of %defattr --- vtun.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 0f84888..d1d0535 100644 --- a/vtun.spec +++ b/vtun.spec @@ -68,7 +68,6 @@ EOT %systemd_postun vtun.service vtun.socket %files -%defattr(-,root,root,-) %doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf %config(noreplace) %{_sysconfdir}/vtund.conf %config(noreplace) %{_sysconfdir}/sysconfig/vtun From 5c99ad0f2bac67503d96ce7bf3245f6d561e8d12 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 14 Jul 2018 08:40:58 +0000 Subject: [PATCH 47/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index d1d0535..4d0bdc7 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 6%{?dist} +Release: 7%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Group: System Environment/Daemons @@ -82,6 +82,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Sat Jul 14 2018 Fedora Release Engineering - 3.0.4-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + * Fri Feb 09 2018 Fedora Release Engineering - 3.0.4-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild From c9ea8c130443a3206958d16854e7a78e77887d47 Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Mon, 28 Jan 2019 20:18:30 +0100 Subject: [PATCH 48/54] Remove obsolete Group tag References: https://fedoraproject.org/wiki/Changes/Remove_Group_Tag --- vtun.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 4d0bdc7..f28a7cd 100644 --- a/vtun.spec +++ b/vtun.spec @@ -3,7 +3,6 @@ Version: 3.0.4 Release: 7%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ -Group: System Environment/Daemons Url: http://vtun.sourceforge.net Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz Source1: vtun.socket From 78922f8841f51a35ad9062247c090b2dccf39b66 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sun, 3 Feb 2019 11:29:06 +0000 Subject: [PATCH 49/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index f28a7cd..51bf3a0 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 7%{?dist} +Release: 8%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Url: http://vtun.sourceforge.net @@ -81,6 +81,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Sun Feb 03 2019 Fedora Release Engineering - 3.0.4-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild + * Sat Jul 14 2018 Fedora Release Engineering - 3.0.4-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild From 81e15b3a03b89bffe0e6076a235720d40f343292 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Wed, 19 Jun 2019 09:57:50 +0200 Subject: [PATCH 50/54] Drop use of __* macros that were removed in rpm-4.15 --- vtun.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index 51bf3a0..be65c69 100644 --- a/vtun.spec +++ b/vtun.spec @@ -39,7 +39,7 @@ require modification to any kernel parts. %patch0 -p1 %build -%{__autoconf} +autoconf # FIXME: Package suffers from c11/inline issues. # Workaround by appending --std=gnu89 to CFLAGS # Proper fix would be to fix the source-code From aa8d4bc89ecdd71a838620428c57f64d99aab8fc Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 27 Jul 2019 03:13:22 +0000 Subject: [PATCH 51/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index be65c69..c382200 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 8%{?dist} +Release: 9%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Url: http://vtun.sourceforge.net @@ -81,6 +81,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Sat Jul 27 2019 Fedora Release Engineering - 3.0.4-9 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild + * Sun Feb 03 2019 Fedora Release Engineering - 3.0.4-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild From 82540dc39744fdb24054196fc989dffcde5ee0c4 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 31 Jan 2020 03:25:41 +0000 Subject: [PATCH 52/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index c382200..b4f1933 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 9%{?dist} +Release: 10%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Url: http://vtun.sourceforge.net @@ -81,6 +81,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Fri Jan 31 2020 Fedora Release Engineering - 3.0.4-10 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + * Sat Jul 27 2019 Fedora Release Engineering - 3.0.4-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild From 4fa3359af56612b1b4539270a66c74212d916769 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Wed, 29 Jul 2020 13:55:01 +0000 Subject: [PATCH 53/54] - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- vtun.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/vtun.spec b/vtun.spec index b4f1933..a64e256 100644 --- a/vtun.spec +++ b/vtun.spec @@ -1,6 +1,6 @@ Name: vtun Version: 3.0.4 -Release: 10%{?dist} +Release: 11%{?dist} Summary: Virtual tunnel over TCP/IP networks License: GPLv2+ Url: http://vtun.sourceforge.net @@ -81,6 +81,9 @@ EOT %{_mandir}/man8/vtund.8* %changelog +* Wed Jul 29 2020 Fedora Release Engineering - 3.0.4-11 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + * Fri Jan 31 2020 Fedora Release Engineering - 3.0.4-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild From 5f702d511109834de5650a8e545c9cf67b0ed872 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= Date: Tue, 3 Nov 2020 00:13:25 +0100 Subject: [PATCH 54/54] Orphaned for 6+ weeks --- .gitignore | 4 - dead.package | 1 + sources | 1 - vtun-nostrip.patch | 12 --- vtun.service | 12 --- vtun.socket | 8 -- vtun.spec | 212 --------------------------------------------- vtun.sysconfig | 16 ---- 8 files changed, 1 insertion(+), 265 deletions(-) delete mode 100644 .gitignore create mode 100644 dead.package delete mode 100644 sources delete mode 100644 vtun-nostrip.patch delete mode 100644 vtun.service delete mode 100644 vtun.socket delete mode 100644 vtun.spec delete mode 100644 vtun.sysconfig diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 2711247..0000000 --- a/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -vtun-3.0.1.tar.gz -/vtun-3.0.1.tar.gz -/vtun-3.0.3.tar.gz -/vtun-3.0.4.tar.gz diff --git a/dead.package b/dead.package new file mode 100644 index 0000000..5204a84 --- /dev/null +++ b/dead.package @@ -0,0 +1 @@ +Orphaned for 6+ weeks diff --git a/sources b/sources deleted file mode 100644 index 1487886..0000000 --- a/sources +++ /dev/null @@ -1 +0,0 @@ -SHA512 (vtun-3.0.4.tar.gz) = b1bb7294bd745c2ca888704e2b0f8e05447b5e01bec0f921648afe363d61a19508dea9e26663993cd69c506aa92621e76f36045bddf7c3723d13a72741ca6781 diff --git a/vtun-nostrip.patch b/vtun-nostrip.patch deleted file mode 100644 index cd07a1a..0000000 --- a/vtun-nostrip.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -NarU5 a/Makefile.in b/Makefile.in ---- a/Makefile.in 2016-10-01 17:46:00.000000000 -0400 -+++ b/Makefile.in 2017-03-17 16:49:16.195772745 -0400 -@@ -97,8 +97,7 @@ - $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(VAR_DIR)/run - $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(STAT_DIR) - $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(LOCK_DIR) - $(INSTALL) -d -m 755 $(INSTALL_OWNER) $(DESTDIR)$(SBIN_DIR) - $(INSTALL) -m 755 $(INSTALL_OWNER) vtund $(DESTDIR)$(SBIN_DIR) -- $(BIN_DIR)/strip $(DESTDIR)$(SBIN_DIR)/vtund - - # DO NOT DELETE THIS LINE -- make depend depends on it. diff --git a/vtun.service b/vtun.service deleted file mode 100644 index d26d83c..0000000 --- a/vtun.service +++ /dev/null @@ -1,12 +0,0 @@ -[Unit] -Description=Virtual Tunnels over TCP/IP networks -After=syslog.target network.target - -[Service] -EnvironmentFile=/etc/sysconfig/vtun -ExecStart=/usr/sbin/vtund -n $OPTIONS -ExecReload=/usr/bin/kill -HUP $MAINPID -Restart=on-failure - -[Install] -WantedBy=multi-user.target diff --git a/vtun.socket b/vtun.socket deleted file mode 100644 index 07f9d3d..0000000 --- a/vtun.socket +++ /dev/null @@ -1,8 +0,0 @@ -[Unit] -Description=Vtun Activation Socket - -[Socket] -ListenStream=5000 - -[Install] -WantedBy=sockets.target diff --git a/vtun.spec b/vtun.spec deleted file mode 100644 index a64e256..0000000 --- a/vtun.spec +++ /dev/null @@ -1,212 +0,0 @@ -Name: vtun -Version: 3.0.4 -Release: 11%{?dist} -Summary: Virtual tunnel over TCP/IP networks -License: GPLv2+ -Url: http://vtun.sourceforge.net -Source0: http://prdownloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz -Source1: vtun.socket -Source2: vtun.service -Source3: vtun.sysconfig -Patch0: vtun-nostrip.patch - -Requires(post): systemd-units -Requires(preun): systemd-units -Requires(postun): systemd-units -BuildRequires: gcc -BuildRequires: zlib-devel lzo-devel bison flex systemd-units autoconf -%if 0%{?fedora} >= 26 -BuildRequires: compat-openssl10-devel -%else -BuildRequires: openssl-devel -%endif - -#enable PIE/PIC: -%global _hardened_build 1 - -%description -VTun provides a method for creating Virtual Tunnels over TCP/IP networks -and allows one to shape, compress, and encrypt traffic in those tunnels. -Supported types of tunnels are: PPP, IP, Ethernet and most other serial -protocols and programs. -VTun is easily and highly configurable: it can be used for various -network tasks like VPN, Mobile IP, Shaped Internet access, IP address -saving, etc. It is completely a user space implementation and does not -require modification to any kernel parts. - -%prep -%setup -q -%patch0 -p1 - -%build -autoconf -# FIXME: Package suffers from c11/inline issues. -# Workaround by appending --std=gnu89 to CFLAGS -# Proper fix would be to fix the source-code -%configure CFLAGS="${RPM_OPT_FLAGS} --std=gnu89" -make %{?_smp_mflags} - -%install -install -D -m 0644 -p %{SOURCE1} %{buildroot}/%{_unitdir}/vtun.socket -install -D -m 0644 -p %{SOURCE2} %{buildroot}/%{_unitdir}/vtun.service -install -D -m 0644 -p %{SOURCE3} %{buildroot}/%{_sysconfdir}/sysconfig/vtun -make install DESTDIR=%{buildroot} INSTALL_OWNER= INSTALL="/usr/bin/install -p" -# tmpfiles.d configuration for /var/lock/vtund: -mkdir -p %{buildroot}/%{_tmpfilesdir} -cat > %{buildroot}/%{_tmpfilesdir}/%{name}.conf << EOT -d %{_localstatedir}/lock/vtund 0755 root root - -EOT - -%post -%systemd_post vtun.service vtun.socket - -%preun -%systemd_preun vtun.service vtun.socket - -%postun -%systemd_postun vtun.service vtun.socket - -%files -%doc ChangeLog Credits FAQ README README.LZO README.Setup README.Shaper TODO vtund.conf -%config(noreplace) %{_sysconfdir}/vtund.conf -%config(noreplace) %{_sysconfdir}/sysconfig/vtun -%{_unitdir}/vtun.socket -%{_unitdir}/vtun.service -%{_sbindir}/vtund -%{_tmpfilesdir}/%{name}.conf -%dir %{_localstatedir}/log/vtund -%dir %{_localstatedir}/lock/vtund -%{_mandir}/man5/vtund.conf.5* -%{_mandir}/man8/vtun.8* -%{_mandir}/man8/vtund.8* - -%changelog -* Wed Jul 29 2020 Fedora Release Engineering - 3.0.4-11 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - -* Fri Jan 31 2020 Fedora Release Engineering - 3.0.4-10 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - -* Sat Jul 27 2019 Fedora Release Engineering - 3.0.4-9 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild - -* Sun Feb 03 2019 Fedora Release Engineering - 3.0.4-8 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild - -* Sat Jul 14 2018 Fedora Release Engineering - 3.0.4-7 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild - -* Fri Feb 09 2018 Fedora Release Engineering - 3.0.4-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild - -* Sat Sep 02 2017 Gabriel Somlo 3.0.3-5 -- remove segfaulting openssl-1.1 patch; use compat-openssl10 instead - -* Sat Sep 02 2017 Gabriel Somlo 3.0.3-4 -- apply openssl-1.1 patch only on Fedora >= 26, to avoid epel7 (#1487003) - -* Thu Aug 03 2017 Fedora Release Engineering - 3.0.4-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild - -* Mon Jul 31 2017 Gabriel Somlo 3.0.3-2 -- add /usr/lib/tmpfiles.d/vtun.conf to enable lock dir. on tmpfs - -* Fri Mar 17 2017 Gabriel Somlo 3.0.3-1 -- update to 3.0.4 -- patch for openssl-1.1 transition - -* Sat Feb 11 2017 Fedora Release Engineering - 3.0.3-16 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild - -* Mon Mar 21 2016 Gabriel Somlo 3.0.3-15 -- patch to fix #1319858,#1319859,#1319861 - -* Fri Feb 05 2016 Fedora Release Engineering - 3.0.3-14 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild - -* Mon Jun 22 2015 Ralf Corsépius - 3.0.3-13 -- Append --stdc=gnu89 to CFLAGS (Work-around to c11/inline compatibility - issues. Fix FTBFS). - -* Fri Jun 19 2015 Fedora Release Engineering - 3.0.3-12 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild - -* Tue Dec 23 2014 Gabriel Somlo 3.0.3-11 -- enhanced service file (remove "KillMode", use default "cgroup" mode) - -* Thu Nov 20 2014 Gabriel Somlo 3.0.3-10 -- enhanced service file (-n to prevent daemonizing vtund) - -* Fri Nov 14 2014 Gabriel Somlo 3.0.3-9 -- added /etc/sysconfig/vtun environment file -- updated unit files - -* Mon Aug 18 2014 Fedora Release Engineering - 3.0.3-8 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild - -* Sun Jun 08 2014 Fedora Release Engineering - 3.0.3-7 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild - -* Sun Aug 04 2013 Fedora Release Engineering - 3.0.3-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild - -* Mon May 13 2013 Gabriel Somlo 3.0.3-5 -- added autoconf step to support aarch64 (#926708) - -* Wed May 01 2013 Gabriel Somlo 3.0.3-4 -- rebuild with PIE (#955286) - -* Fri Feb 15 2013 Fedora Release Engineering -- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild - -* Sun Sep 16 2012 Gabriel Somlo 3.0.3-2 -- avoid stripping too early to preserve debuginfo (#857716) - -* Thu Sep 13 2012 Gabriel Somlo 3.0.3-1 -- update to 3.0.3 -- new systemd-rpm macros (#850362) - -* Sun Jul 22 2012 Fedora Release Engineering - 3.0.1-15 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild - -* Mon May 21 2012 Peter Robinson - 3.0.1-14 -- Fix unit file location, cleanup and modernise spec - -* Sat Jan 14 2012 Fedora Release Engineering - 3.0.1-13 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild - -* Sat Sep 10 2011 Gabriel Somlo 3.0.1-12 -- removed xinetd and sysvinit support - -* Sat Sep 10 2011 Gabriel Somlo 3.0.1-11 -- update support for systemd (#737195) - -* Mon Feb 07 2011 Fedora Release Engineering - 3.0.1-10 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild - -* Thu Jan 06 2011 Gabriel Somlo 3.0.1-9 -- add support for systemd (#661331) - -* Tue Nov 30 2010 Gabriel Somlo 3.0.1-8 -- using ghost on /var/lock/vtund directory (#656720) - -* Fri Aug 21 2009 Tomas Mraz - 3.0.1-7 -- rebuilt with new openssl - -* Sun Jul 26 2009 Fedora Release Engineering - 3.0.1-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild - -* Wed Feb 25 2009 Fedora Release Engineering - 3.0.1-5 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild - -* Sun Jan 18 2009 Tomas Mraz 3.0.1-4 -- rebuild with new openssl - -* Mon Nov 17 2008 Gabriel Somlo 3.0.1-3 -- scriptlets fixes - -* Fri Nov 14 2008 Gabriel Somlo 3.0.1-2 -- spec file fixes: defattr, -p flag to install program - -* Mon Oct 20 2008 Gabriel Somlo 3.0.1-1 -- initial fedora package diff --git a/vtun.sysconfig b/vtun.sysconfig deleted file mode 100644 index 467bd8b..0000000 --- a/vtun.sysconfig +++ /dev/null @@ -1,16 +0,0 @@ -# Comment out one of the following for client or server mode -# -# To run vtun as a server: -# -#OPTIONS='-s' -# -# -# -#To run vtun as a client, we need: -# -# - session name, e.g. "lion"; must be present in both client and server -# config files. -# -# - server address or host name. -# -#OPTIONS='lion vtun-server.example.com'