summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhubertf <hubertf@pkgsrc.org>2003-09-16 13:05:55 +0000
committerhubertf <hubertf@pkgsrc.org>2003-09-16 13:05:55 +0000
commit14d96003b2b84440bb5d5580cea4a7e1b7bb578a (patch)
tree9d96b1c21cf4b6d25845ff8cfeb19cfb8e757367
parent517a60d0fc82a61d717e15f143f6bcb89282fe4c (diff)
downloadpkgsrc-14d96003b2b84440bb5d5580cea4a7e1b7bb578a.tar.gz
Update to ht6to4-1.1. Changes:
* also remove 6to4 addresses from internal interface, if set * doc updates Inspired by patch sent by Markus W Kilbinger <kilbi@rad.rwth-aachen.de> in private mail.
-rw-r--r--doc/CHANGES3
-rw-r--r--net/hf6to4/Makefile4
-rwxr-xr-xnet/hf6to4/files/hf6to422
-rw-r--r--net/hf6to4/files/hf6to4.88
-rw-r--r--net/hf6to4/files/hf6to4.conf2
5 files changed, 32 insertions, 7 deletions
diff --git a/doc/CHANGES b/doc/CHANGES
index a2671136117..8df611a2227 100644
--- a/doc/CHANGES
+++ b/doc/CHANGES
@@ -1,4 +1,4 @@
-$NetBSD: CHANGES,v 1.3397 2003/09/16 13:02:28 gehenna Exp $
+$NetBSD: CHANGES,v 1.3398 2003/09/16 13:05:55 hubertf Exp $
Changes to the packages collection and infrastructure in 2003:
@@ -3717,3 +3717,4 @@ Changes to the packages collection and infrastructure in 2003:
Added fuse-utils-0.6.1 [adam 2003-09-16]
Updated openal to 20030724 [adam 2003-09-16]
Updated cvsync to 0.24.7 [gehenna 2003-09-16]
+ Updated hf6to4 to 1.1 [hubertf 2003-09-16]
diff --git a/net/hf6to4/Makefile b/net/hf6to4/Makefile
index 44819f199f7..46a0e5cb683 100644
--- a/net/hf6to4/Makefile
+++ b/net/hf6to4/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.1.1.1 2003/08/23 13:30:35 hubertf Exp $
+# $NetBSD: Makefile,v 1.2 2003/09/16 13:05:57 hubertf Exp $
#
-DISTNAME= hf6to4-1.0
+DISTNAME= hf6to4-1.1
WRKSRC= ${WRKDIR}
CATEGORIES= net
MASTER_SITES= # empty
diff --git a/net/hf6to4/files/hf6to4 b/net/hf6to4/files/hf6to4
index de79d05f99f..011b8276076 100755
--- a/net/hf6to4/files/hf6to4
+++ b/net/hf6to4/files/hf6to4
@@ -171,6 +171,22 @@ then
run ifconfig stf0 inet6 -alias $adr
done
+ # remove v6 addresses from internal interface
+ if [ "$in_if" != "" ]
+ then
+ adrs=`ifconfig $in_if inet6 \
+ | grep inet6 \
+ | grep "2002:.*:$v6_innernet:$hostbits6" \
+ | sed -e 's/inet6//' \
+ -e 's/prefix.*//g' \
+ -e 's/^[ ]*//' \
+ -e 's/[ ]*\$//'`
+ for adr in $adrs
+ do
+ run ifconfig $in_if inet6 -alias $adr
+ done
+ fi
+
# remove default route:
run route delete -inet6 default
fi
@@ -180,7 +196,7 @@ fi
if [ "$1" = "start" ]
then
run ifconfig stf0 inet6 $localadr6:$hostbits6 prefixlen $v6_prefixlen alias
- run route add -inet6 default $remoteadr6
+ run route add -inet6 default $remoteadr6 >/dev/null
if [ "$in_if" != "" ]
then
run ifconfig $in_if inet6 $prefix:$v6_innernet:$hostbits6
@@ -188,6 +204,8 @@ then
fi
# rtadvd-stop:
+#
+# XXX maybe better do this via rc.conf & rc.d/rtadvd?
if [ "$1" = "rtadvd-stop" -o "$1" = "stop-rtadvd" ]
then
if [ -f "/var/run/rtadvd.pid" ]
@@ -201,6 +219,8 @@ then
fi
# rtadvd-start:
+#
+# XXX maybe better do this via rc.conf & rc.d/rtadvd?
if [ "$1" = "rtadvd-start" -o "$1" = "start-rtadvd" ]
then
if [ -f "/var/run/rtadvd.pid" ]
diff --git a/net/hf6to4/files/hf6to4.8 b/net/hf6to4/files/hf6to4.8
index 2d1f02381e3..b35892f4d26 100644
--- a/net/hf6to4/files/hf6to4.8
+++ b/net/hf6to4/files/hf6to4.8
@@ -1,4 +1,4 @@
-.\" $NetBSD: hf6to4.8,v 1.1.1.1 2003/08/23 13:30:35 hubertf Exp $
+.\" $NetBSD: hf6to4.8,v 1.2 2003/09/16 13:05:58 hubertf Exp $
.Dd August 23, 2003
.Dt hf6to4 8
.Os
@@ -56,7 +56,9 @@ network interface is assigned an address.
.It Sy stop
Stops 6to4 IPv6. All addresses are removed from the
.Xr stf 4
-device, and the default route is removed.
+device, and the default route is removed. If
+.Sy in_if
+is set, the 6to4 adresses are removed from that interface too.
.It Sy rtadvd-start
Starts router advertizement and IPv6 packet forwarding,
turning the machine into a IPv6 router.
@@ -206,3 +208,5 @@ Hubert Feyrer <hubert@feyrer.de>.
On systems running past-1.5, the
.Dq ifconfig stf0 create
should be run automatically.
+.Pp
+Might be good to use /etc/rc.d/rtadvd for rtadvd handling.
diff --git a/net/hf6to4/files/hf6to4.conf b/net/hf6to4/files/hf6to4.conf
index 70cc7fbd1eb..0eda7c8ae76 100644
--- a/net/hf6to4/files/hf6to4.conf
+++ b/net/hf6to4/files/hf6to4.conf
@@ -21,7 +21,7 @@ hostbits6=":1" # should be determined via MAC of $in_if
#peer="6to4.ipv6.fh-regensburg.de" # Germany, Europe
#peer="6to4-anycast" # use RFC 3068 magic values
#peer="asterix.ipv6.bt.com" # Great Britain, Europe
-#$peer="6to4.kfu.com" # USA, West coast
+#peer="6to4.kfu.com" # USA, West coast
#peer="6to4.ipv6.microsoft.com" # USA, West coast
#peer="ipv6-router.cisco.com" # USA, West coast; register at http://www.cisco.com/ipv6/