Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Jan 2008 03:12:43 -0500
From:      Yarema <yds@CoolRat.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        sumikawa@FreeBSD.org
Subject:   ports/119795: update security/racoon2 to 20071227d
Message-ID:  <courier.000000004791B0FB.0000FED4@dppl.com>
Resent-Message-ID: <200801190820.m0J8K18M077880@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         119795
>Category:       ports
>Synopsis:       update security/racoon2 to 20071227d
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jan 19 08:20:01 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Yarema
>Release:        FreeBSD 6.3-PRERELEASE amd64
>Organization:
NYCBUG.org
>Environment:
System:	FreeBSD 6.3-PRERELEASE amd64
	FreeBSD 7.0-PRERELEASE amd64
>Description:
This update removes patches:
	files/patch-fastipsec
	files/patch-rcvar
and adds patches:
	files/patch-samples-rc.d-racoon2.in
	files/patch-samples-rc.d-spmd.in

The new samples/Makefile.in incorrectly hardcodes
sysconfdir=@sysconfdir@/racoon2
which then intruduces inconsistencies with other files that do not
hardcode this value (e.g. the rc.d scripts). This is corrected by
the new patch-samples-Makefile.in file and by setting
CONFIGURE_ARGS+=	--sysconfdir=${PREFIX}/etc/racoon2
etc/rc.d/racoon2 is now installed as well.  And all the rc.d scripts now
install without the .sh extention.

pkg-plist is reworked to install and remove .conf files without the .sample
extention unless a modified file already exists.  Also /var/run/racoon2 is
now removed on deinstall.
>How-To-Repeat:
cd /usr/ports/security/racoon2 && make install
>Fix:
diff -u -r -N racoon2-20070720a/Makefile racoon2/Makefile
--- racoon2-20070720a/Makefile	2007-09-30 03:42:32.000000000 -0400
+++ racoon2/Makefile	2008-01-19 02:11:23.946721912 -0500
@@ -6,8 +6,8 @@
 #
 
 PORTNAME=	racoon2
-PORTVERSION=	20070720a
-PORTREVISION=	3
+PORTVERSION=	20071227d
+#PORTREVISION=	0
 CATEGORIES=	security net ipv6
 MASTER_SITES=	ftp://ftp.racoon2.wide.ad.jp/pub/racoon2/
 EXTRACT_SUFX=	.tgz
@@ -21,7 +21,7 @@
 USE_AUTOTOOLS=	autoconf:261
 CONFIGURE_TARGET=
 GNU_CONFIGURE=	yes
-CONFIGURE_ARGS+=	--sysconfdir=${LOCALBASE}/etc
+CONFIGURE_ARGS+=	--sysconfdir=${PREFIX}/etc/racoon2
 
 OPTIONS=	KINK "enable KINK support" off
 
@@ -73,6 +73,10 @@
 	${INSTALL_DATA} ${WRKSRC}/doc/${FILE} ${DOCSDIR}
 .endfor
 .endif
+	@${GREP} '^@exec ' ${TMPPLIST} \
+		| ${SED} -e 's:^@exec ::' -e 's:%D:${PREFIX}:g' \
+		> ${WRKDIR}/.PLIST.exec \
+		&& ${SH} ${WRKDIR}/.PLIST.exec
 	@if [ -z `/sbin/sysctl -a | ${GREP} -q ipsec && echo ipsec` ]; then \
 	    ${ECHO_MSG} "WARNING: IPsec feature is disabled on this host"; \
 	    ${ECHO_MSG} "         You must build the kernel if you want to run racoon on the host"; \
diff -u -r -N racoon2-20070720a/distinfo racoon2/distinfo
--- racoon2-20070720a/distinfo	2007-07-23 06:18:44.000000000 -0400
+++ racoon2/distinfo	2008-01-18 19:07:29.851047682 -0500
@@ -1,3 +1,3 @@
-MD5 (racoon2-20070720a.tgz) = 90ae6aaf556e142393a80808cd881a51
-SHA256 (racoon2-20070720a.tgz) = e2a4960eb1b2b91940d39154c2fc0cf5061f2aece14d3b58424584fa7be23420
-SIZE (racoon2-20070720a.tgz) = 982736
+MD5 (racoon2-20071227d.tgz) = 412cd5724e9d1a109bbca99e1aeeea37
+SHA256 (racoon2-20071227d.tgz) = 010952527a44b1b3fcb6ef4f261173e937dbebcce4c4fbf3434d3fe90faebb1e
+SIZE (racoon2-20071227d.tgz) = 1000673
diff -u -r -N racoon2-20070720a/files/patch-configure racoon2/files/patch-configure
--- racoon2-20070720a/files/patch-configure	2006-05-30 00:02:11.000000000 -0400
+++ racoon2/files/patch-configure	2007-12-26 20:08:52.000000000 -0500
@@ -1,7 +1,7 @@
---- configure-	Tue May 30 12:46:28 2006
-+++ configure	Tue May 30 12:47:05 2006
-@@ -1517,7 +1517,7 @@
- 	netbsd1.[56]*|netbsd[2-9].*)
+--- configure.orig	2007-12-26 20:08:52.000000000 -0500
++++ configure	2007-12-26 20:08:52.000000000 -0500
+@@ -784,7 +784,7 @@
+ 	netbsd*1.[56]*|netbsd*[2-9].*)
  		startup_scripts=rc-d
  		;;
 -	freebsd[5-9].*)
diff -u -r -N racoon2-20070720a/files/patch-samples-Makefile.in racoon2/files/patch-samples-Makefile.in
--- racoon2-20070720a/files/patch-samples-Makefile.in	2006-07-18 04:17:30.000000000 -0400
+++ racoon2/files/patch-samples-Makefile.in	2007-12-26 20:08:52.000000000 -0500
@@ -1,18 +1,30 @@
---- samples/Makefile.in.orig	Tue Nov  8 05:53:50 2005
-+++ samples/Makefile.in	Sat Jul 15 17:50:25 2006
-@@ -18,10 +18,11 @@
+--- samples/Makefile.in.orig	2007-12-26 20:08:52.000000000 -0500
++++ samples/Makefile.in	2007-12-26 20:08:52.000000000 -0500
+@@ -2,7 +2,7 @@
+ 
+ srcdir=@srcdir@
+ prefix=@prefix@
+-sysconfdir=@sysconfdir@/racoon2
++sysconfdir=@sysconfdir@
+ INSTALL =@INSTALL@ @INSTALL_OPTS@
+ INSTALL_PROGRAM=@INSTALL_PROGRAM@
+ INSTALL_DATA=@INSTALL_DATA@
+@@ -29,11 +29,13 @@
+ 	$(INSTALL) -d -m 700 $(sysconfdir)/cert
  
  install-startup-rc-d:
- 	$(INSTALL) -d $(sysconfdir)/rc.d
+-	$(INSTALL) -d $(sysconfdir)/rc.d
 -	$(INSTALL_SCRIPT) rc.d-iked $(sysconfdir)/rc.d/iked
 -	$(INSTALL_SCRIPT) rc.d-kinkd $(sysconfdir)/rc.d/kinkd
 -	$(INSTALL_SCRIPT) rc.d-spmd $(sysconfdir)/rc.d/spmd
 -	$(INSTALL_SCRIPT) rc.d-racoon2 $(sysconfdir)/rc.d/racoon2
-+	$(INSTALL_SCRIPT) rc.d-iked $(sysconfdir)/rc.d/iked.sh
++	$(INSTALL) -d $(prefix)/etc/rc.d
++	$(INSTALL_SCRIPT) rc.d-iked $(prefix)/etc/rc.d/iked
 +.if defined (WITH_KINK)
-+	$(INSTALL_SCRIPT) rc.d-kinkd $(sysconfdir)/rc.d/kinkd.sh
++	$(INSTALL_SCRIPT) rc.d-kinkd $(prefix)/etc/rc.d/kinkd
 +.endif
-+	$(INSTALL_SCRIPT) rc.d-spmd $(sysconfdir)/rc.d/spmd.sh
++	$(INSTALL_SCRIPT) rc.d-spmd $(prefix)/etc/rc.d/spmd
++	$(INSTALL_SCRIPT) rc.d-racoon2 $(prefix)/etc/rc.d/racoon2
  
  install-startup-init-d:
  	$(INSTALL) -d $(sysconfdir)/init.d
diff -u -r -N racoon2-20070720a/files/patch-samples-rc.d-iked.in racoon2/files/patch-samples-rc.d-iked.in
--- racoon2-20070720a/files/patch-samples-rc.d-iked.in	2006-06-07 03:33:35.000000000 -0400
+++ racoon2/files/patch-samples-rc.d-iked.in	2005-10-28 02:33:16.000000000 -0400
@@ -1,7 +1,11 @@
---- samples/rc.d-iked.in.orig	Fri Oct 28 15:33:16 2005
-+++ samples/rc.d-iked.in	Wed Jun  7 16:03:18 2006
-@@ -17,7 +17,7 @@
- rcvar=$name
+--- samples/rc.d-iked.in.orig	2005-10-28 02:33:16.000000000 -0400
++++ samples/rc.d-iked.in	2005-10-28 02:33:16.000000000 -0400
+@@ -14,10 +14,10 @@
+ exec_prefix=@exec_prefix@
+ 
+ name="iked"
+-rcvar=$name
++rcvar=`set_rcvar`
  command="@sbindir@/${name}"
  extra_commands="reload"
 -required_vars="spmd"
diff -u -r -N racoon2-20070720a/files/patch-samples-rc.d-kinkd.in racoon2/files/patch-samples-rc.d-kinkd.in
--- racoon2-20070720a/files/patch-samples-rc.d-kinkd.in	2006-07-17 13:01:21.000000000 -0400
+++ racoon2/files/patch-samples-rc.d-kinkd.in	2005-10-28 02:33:16.000000000 -0400
@@ -1,7 +1,11 @@
---- samples/rc.d-kinkd.in~	Sun Jul 16 00:23:47 2006
-+++ samples/rc.d-kinkd.in	Tue Jul 18 01:20:34 2006
-@@ -17,7 +17,7 @@
- rcvar=`set_rcvar`
+--- samples/rc.d-kinkd.in.orig	2005-10-28 02:33:16.000000000 -0400
++++ samples/rc.d-kinkd.in	2005-10-28 02:33:16.000000000 -0400
+@@ -14,10 +14,10 @@
+ exec_prefix=@exec_prefix@
+ 
+ name="kinkd"
+-rcvar=$name
++rcvar=`set_rcvar`
  command="@sbindir@/${name}"
  extra_commands="reload"
 -required_vars="spmd"
diff -u -r -N racoon2-20070720a/files/patch-samples-rc.d-racoon2.in racoon2/files/patch-samples-rc.d-racoon2.in
--- racoon2-20070720a/files/patch-samples-rc.d-racoon2.in	1969-12-31 19:00:00.000000000 -0500
+++ racoon2/files/patch-samples-rc.d-racoon2.in	2008-01-19 00:15:12.004424881 -0500
@@ -0,0 +1,19 @@
+--- samples/rc.d-racoon2.in.orig	2005-10-28 02:33:16.000000000 -0400
++++ samples/rc.d-racoon2.in	2005-10-28 02:33:16.000000000 -0400
+@@ -10,11 +10,12 @@
+ #
+ # Example) If you want to use only IKEv2, put the following lines into
+ # /etc/rc.conf.
+-#        spmd=YES
+-#        iked=YES
+-#        kinkd=NO
++#        spmd_enable=YES
++#        iked_enable=YES
++#        kinkd_enable=NO
+ # When the system is booting, spmd and iked are started by /etc/rc.
+-# When you want start/stop manually, use /etc/rc.d/racoon2 start (or stop).
++# When you want start/stop manually, use
++#	@prefix@/etc/rc.d/racoon2 start (or stop).
+ 
+ . /etc/rc.subr
+ 
diff -u -r -N racoon2-20070720a/files/patch-samples-rc.d-spmd.in racoon2/files/patch-samples-rc.d-spmd.in
--- racoon2-20070720a/files/patch-samples-rc.d-spmd.in	1969-12-31 19:00:00.000000000 -0500
+++ racoon2/files/patch-samples-rc.d-spmd.in	2007-07-10 20:59:30.000000000 -0400
@@ -0,0 +1,11 @@
+--- samples/rc.d-spmd.in.orig	2007-07-10 20:59:30.000000000 -0400
++++ samples/rc.d-spmd.in	2007-07-10 20:59:30.000000000 -0400
+@@ -13,7 +13,7 @@
+ exec_prefix=@exec_prefix@
+ 
+ name="spmd"
+-rcvar=$name
++rcvar=`set_rcvar`
+ command="@sbindir@/${name}"
+ extra_commands="reload"
+ pidfile="/var/run/${name}.pid"
diff -u -r -N racoon2-20070720a/pkg-plist racoon2/pkg-plist
--- racoon2-20070720a/pkg-plist	2007-07-27 03:41:39.000000000 -0400
+++ racoon2/pkg-plist	2008-01-19 02:27:38.221478915 -0500
@@ -1,21 +1,66 @@
+@unexec if cmp -s %D/etc/racoon2/default.conf.sample %D/etc/racoon2/default.conf;then rm -f %D/etc/racoon2/default.conf;fi
+etc/racoon2/default.conf.sample
+@exec [ -f %D/etc/racoon2/default.conf ] || cp -p %D/etc/racoon2/default.conf.sample %D/etc/racoon2/default.conf
+etc/racoon2/hook/child-down
+etc/racoon2/hook/child-rekey
+etc/racoon2/hook/child-up
+etc/racoon2/hook/child-up.d/00childup_sample
+etc/racoon2/hook/functions
+etc/racoon2/hook/ikesa-down
+etc/racoon2/hook/ikesa-rekey
+etc/racoon2/hook/ikesa-up
+etc/racoon2/hook/ikesa-up.d/00ikesaup_sample
+etc/racoon2/hook/migration
+etc/racoon2/hook/ph1-down
+etc/racoon2/hook/ph1-up
+@unexec if cmp -s %D/etc/racoon2/local-test.conf.sample %D/etc/racoon2/local-test.conf;then rm -f %D/etc/racoon2/local-test.conf;fi
+etc/racoon2/local-test.conf.sample
+@exec [ -f %D/etc/racoon2/local-test.conf ] || cp -p %D/etc/racoon2/local-test.conf.sample %D/etc/racoon2/local-test.conf
+@unexec if cmp -s %D/etc/racoon2/racoon2.conf.sample %D/etc/racoon2/racoon2.conf;then rm -f %D/etc/racoon2/racoon2.conf;fi
+etc/racoon2/racoon2.conf.sample
+@exec [ -f %D/etc/racoon2/racoon2.conf ] || cp -p %D/etc/racoon2/racoon2.conf.sample %D/etc/racoon2/racoon2.conf
+etc/racoon2/spmd.pwd
+@unexec if cmp -s %D/etc/racoon2/transport_ike.conf.sample %D/etc/racoon2/transport_ike.conf;then rm -f %D/etc/racoon2/transport_ike.conf;fi
+etc/racoon2/transport_ike.conf.sample
+@exec [ -f %D/etc/racoon2/transport_ike.conf ] || cp -p %D/etc/racoon2/transport_ike.conf.sample %D/etc/racoon2/transport_ike.conf
+@unexec if cmp -s %D/etc/racoon2/transport_kink.conf.sample %D/etc/racoon2/transport_kink.conf;then rm -f %D/etc/racoon2/transport_kink.conf;fi
+etc/racoon2/transport_kink.conf.sample
+@exec [ -f %D/etc/racoon2/transport_kink.conf ] || cp -p %D/etc/racoon2/transport_kink.conf.sample %D/etc/racoon2/transport_kink.conf
+@unexec if cmp -s %D/etc/racoon2/tunnel_ike.conf.sample %D/etc/racoon2/tunnel_ike.conf;then rm -f %D/etc/racoon2/tunnel_ike.conf;fi
+etc/racoon2/tunnel_ike.conf.sample
+@exec [ -f %D/etc/racoon2/tunnel_ike.conf ] || cp -p %D/etc/racoon2/tunnel_ike.conf.sample %D/etc/racoon2/tunnel_ike.conf
+@unexec if cmp -s %D/etc/racoon2/tunnel_ike_natt.conf.sample %D/etc/racoon2/tunnel_ike_natt.conf;then rm -f %D/etc/racoon2/tunnel_ike_natt.conf;fi
+etc/racoon2/tunnel_ike_natt.conf.sample
+@exec [ -f %D/etc/racoon2/tunnel_ike_natt.conf ] || cp -p %D/etc/racoon2/tunnel_ike_natt.conf.sample %D/etc/racoon2/tunnel_ike_natt.conf
+@unexec if cmp -s %D/etc/racoon2/tunnel_kink.conf.sample %D/etc/racoon2/tunnel_kink.conf;then rm -f %D/etc/racoon2/tunnel_kink.conf;fi
+etc/racoon2/tunnel_kink.conf.sample
+@exec [ -f %D/etc/racoon2/tunnel_kink.conf ] || cp -p %D/etc/racoon2/tunnel_kink.conf.sample %D/etc/racoon2/tunnel_kink.conf
+@unexec if cmp -s %D/etc/racoon2/vals.conf.sample %D/etc/racoon2/vals.conf;then rm -f %D/etc/racoon2/vals.conf;fi
+etc/racoon2/vals.conf.sample
+@exec [ -f %D/etc/racoon2/vals.conf ] || cp -p %D/etc/racoon2/vals.conf.sample %D/etc/racoon2/vals.conf
+etc/rc.d/iked
+%%KINK%%etc/rc.d/kinkd
+etc/rc.d/racoon2
+etc/rc.d/spmd
 sbin/iked
 %%KINK%%sbin/kinkd
 sbin/spmd
 sbin/spmdctl
 sbin/pskgen
-etc/spmd.pwd
-etc/default.conf.sample
-etc/local-test.conf.sample
-etc/racoon2.conf.sample
-etc/transport_ike.conf.sample
-etc/transport_kink.conf.sample
-etc/tunnel_ike.conf.sample
-etc/tunnel_ike_natt.conf.sample
-etc/tunnel_kink.conf.sample
-etc/vals.conf.sample
-etc/rc.d/iked.sh
-etc/rc.d/spmd.sh
-%%KINK%%etc/rc.d/kinkd.sh
 %%PORTDOCS%%%%DOCSDIR%%/COPYRIGHT
 %%PORTDOCS%%%%DOCSDIR%%/COPYRIGHT.jp
 %%PORTDOCS%%%%DOCSDIR%%/README
+@dirrmtry etc/racoon2/psk
+@dirrmtry etc/racoon2/hook/ph1-up.d
+@dirrmtry etc/racoon2/hook/ph1-down.d
+@dirrmtry etc/racoon2/hook/migration.d
+@dirrmtry etc/racoon2/hook/ikesa-up.d
+@dirrmtry etc/racoon2/hook/ikesa-rekey.d
+@dirrmtry etc/racoon2/hook/ikesa-down.d
+@dirrmtry etc/racoon2/hook/child-up.d
+@dirrmtry etc/racoon2/hook/child-rekey.d
+@dirrmtry etc/racoon2/hook/child-down.d
+@dirrmtry etc/racoon2/hook
+@dirrmtry etc/racoon2/cert
+@dirrmtry etc/racoon2
+@unexec rm -rf /var/run/racoon2 || true
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?courier.000000004791B0FB.0000FED4>