aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhrs <hrs@FreeBSD.org>2012-10-03 04:26:17 +0800
committerhrs <hrs@FreeBSD.org>2012-10-03 04:26:17 +0800
commitdde83cf5222d0711b287d13c3e7378138851da3c (patch)
treeba3e0e90e172209df19d0dd5b5ee41b2dcd1da0c
parentfacae4f7caf1100ae14efdd7873613d7f0e184b4 (diff)
downloadfreebsd-ports-gnome-dde83cf5222d0711b287d13c3e7378138851da3c.tar.gz
freebsd-ports-gnome-dde83cf5222d0711b287d13c3e7378138851da3c.tar.zst
freebsd-ports-gnome-dde83cf5222d0711b287d13c3e7378138851da3c.zip
Add net-mgmt/ipv6mon, a tool for monitoring IPv6 address usage on a local
network. WWW: http://www.si6networks.com/tools/ipv6mon/
-rw-r--r--GIDs1
-rw-r--r--UIDs1
-rw-r--r--net-mgmt/Makefile1
-rw-r--r--net-mgmt/ipv6mon/Makefile45
-rw-r--r--net-mgmt/ipv6mon/distinfo2
-rw-r--r--net-mgmt/ipv6mon/files/ipv6mon.in18
-rw-r--r--net-mgmt/ipv6mon/files/patch-Makefile19
-rw-r--r--net-mgmt/ipv6mon/files/patch-ipv6mon.c21
-rw-r--r--net-mgmt/ipv6mon/pkg-descr8
-rw-r--r--net-mgmt/ipv6mon/pkg-plist5
10 files changed, 121 insertions, 0 deletions
diff --git a/GIDs b/GIDs
index f34429da0816..81f10484002c 100644
--- a/GIDs
+++ b/GIDs
@@ -81,6 +81,7 @@ dovenull:*:144:
webcamd:*:145:
ventrilo:*:146:
kdm:*:147:
+ipv6mon:*:148:
rbldns:*:153:
trircd:*:154:
sfs:*:171:
diff --git a/UIDs b/UIDs
index 5ce026765f66..7923ba63b760 100644
--- a/UIDs
+++ b/UIDs
@@ -88,6 +88,7 @@ dovenull:*:144:144::0:0:Dovecot login User:/var/empty:/usr/sbin/nologin
webcamd:*:145:145::0:0:Webcamd user:/var/empty:/usr/sbin/nologin
ventrilo:*:146:146::0:0:& server:/usr/local/ventrilo-server:/usr/sbin/nologin
kdm:*:147:147::0:0:KDE Display Manager:/nonexistent:/usr/sbin/nologin
+ipv6mon:*:148:148::0:0:IPv6 Address Monitoring Daemon:/nonexistent:/usr/sbin/nologin
rbldns:*:153:153::0:0:rbldnsd pseudo-user:/nonexistent:/usr/sbin/nologin
trircd:*:154:154::0:0:& user:/usr/local/etc/tr-ircd:/usr/sbin/nologin
sfs:*:171:171::0:0:Self-Certifying File System:/nonexistent:/usr/sbin/nologin
diff --git a/net-mgmt/Makefile b/net-mgmt/Makefile
index b0ae20e4fa0e..b0d7a0527e85 100644
--- a/net-mgmt/Makefile
+++ b/net-mgmt/Makefile
@@ -98,6 +98,7 @@
SUBDIR += ipplan
SUBDIR += ipv6calc
SUBDIR += ipv6gen
+ SUBDIR += ipv6mon
SUBDIR += irrtoolset
SUBDIR += isic
SUBDIR += jnettop
diff --git a/net-mgmt/ipv6mon/Makefile b/net-mgmt/ipv6mon/Makefile
new file mode 100644
index 000000000000..04988aab293e
--- /dev/null
+++ b/net-mgmt/ipv6mon/Makefile
@@ -0,0 +1,45 @@
+# Created by: Hiroki Sato <hrs@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= ipv6mon
+PORTVERSION= 1.0
+CATEGORIES= net-mgmt ipv6
+MASTER_SITES= http://www.si6networks.com/tools/ipv6mon/
+DISTNAME= ${PORTNAME}-v${PORTVERSION}
+
+MAINTAINER= hrs@FreeBSD.org
+COMMENT= Tool for monitoring IPv6 address usage
+
+LICENSE= GPLv3
+
+MAKE_ENV= DESTDIR=${PREFIX}/
+CFLAGS+= -DIPV6MON_CONF=\\\"${PREFIX}/etc/ipv6mon.conf\\\"
+USERS= ${PORTNAME}
+GROUPS= ${PORTNAME}
+USE_RC_SUBR= ${PORTNAME}
+
+MAN5= ipv6mon.conf.5
+MAN8= ipv6mon.8
+
+PORTDOCS= README.TXT \
+ ipv6mon-installation-notes.odt \
+ ipv6mon-installation-notes.pdf \
+ ipv6mon-manual.odt \
+ ipv6mon-manual.pdf
+
+post-extract:
+ ${INSTALL_DATA} ${WRKSRC}/manuals/* ${WRKSRC}
+
+post-install:
+ if [ ! -r ${PREFIX}/etc/ipv6mon.conf ]; then \
+ ${INSTALL_DATA} ${PREFIX}/etc/ipv6mon.conf.dist \
+ ${PREFIX}/etc/ipv6mon.conf; \
+ fi
+ ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME} ${PREFIX}/etc/rc.d
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+ cd ${WRKSRC} && \
+ ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}
+.endif
+
+.include <bsd.port.mk>
diff --git a/net-mgmt/ipv6mon/distinfo b/net-mgmt/ipv6mon/distinfo
new file mode 100644
index 000000000000..70941fde0037
--- /dev/null
+++ b/net-mgmt/ipv6mon/distinfo
@@ -0,0 +1,2 @@
+SHA256 (ipv6mon-v1.0.tar.gz) = f714a877de4fbf80126c4b8ad2e3496739695ee1eb3a914eae344fdd6325e138
+SIZE (ipv6mon-v1.0.tar.gz) = 211625
diff --git a/net-mgmt/ipv6mon/files/ipv6mon.in b/net-mgmt/ipv6mon/files/ipv6mon.in
new file mode 100644
index 000000000000..9637bbabe808
--- /dev/null
+++ b/net-mgmt/ipv6mon/files/ipv6mon.in
@@ -0,0 +1,18 @@
+#!/bin/sh
+# $FreeBSD$
+
+# PROVIDE: ipv6mon
+# REQUIRE: DAEMON
+# BEFORE: LOGIN
+# KEYWORD: nojail shutdown
+
+. /etc/rc.subr
+
+name="ipv6mon"
+rcvar=$name
+command="%%PREFIX%%/sbin/${name}"
+pidfile="/var/run/${name}.pid"
+required_files="%%PREFIX%%/etc/${name}.conf"
+
+load_rc_config $name
+run_rc_command "$1"
diff --git a/net-mgmt/ipv6mon/files/patch-Makefile b/net-mgmt/ipv6mon/files/patch-Makefile
new file mode 100644
index 000000000000..27ebd3bafbd3
--- /dev/null
+++ b/net-mgmt/ipv6mon/files/patch-Makefile
@@ -0,0 +1,19 @@
+--- /dev/null 2012-09-18 11:55:15.000000000 +0900
++++ Makefile 2012-09-18 11:55:52.000000000 +0900
+@@ -0,0 +1,16 @@
++# $FreeBSD$
++
++PROG= ipv6mon
++LDADD= -lpcap
++
++FILES= ipv6mon.conf
++FILESNAME= ipv6mon.conf.dist
++FILESDIR= etc
++
++BINDIR= sbin
++MANDIR= man/man
++
++MAN= ipv6mon.8 ipv6mon.conf.5
++NO_MANCOMPRESS=
++
++.include <bsd.prog.mk>
diff --git a/net-mgmt/ipv6mon/files/patch-ipv6mon.c b/net-mgmt/ipv6mon/files/patch-ipv6mon.c
new file mode 100644
index 000000000000..5e67c75a4b66
--- /dev/null
+++ b/net-mgmt/ipv6mon/files/patch-ipv6mon.c
@@ -0,0 +1,21 @@
+--- ipv6mon.c.orig 2012-09-20 13:02:24.000000000 +0900
++++ ipv6mon.c 2012-09-20 13:02:26.000000000 +0900
+@@ -277,7 +277,7 @@
+ }
+
+ if(!configfile_f){
+- configfile="/etc/ipv6mon.conf";
++ configfile=IPV6MON_CONF;
+ }
+
+ if(process_config_file(configfile) == -1)
+@@ -888,7 +888,8 @@
+ usage();
+
+ puts("\nOPTIONS:\n"
+- " --config-file, -c Configuration file pathname (defaults to '/etc/ipv6mon.conf')\n"
++ " --config-file, -c Configuration file pathname (defaults to '"
++ IPV6MON_CONF "')\n"
+ " --show-config, -q Shows configuration values and quits\n"
+ " --help, -h Print help for the scan6 tool\n"
+ " --verbose, -v Be verbose\n"
diff --git a/net-mgmt/ipv6mon/pkg-descr b/net-mgmt/ipv6mon/pkg-descr
new file mode 100644
index 000000000000..374e710509d4
--- /dev/null
+++ b/net-mgmt/ipv6mon/pkg-descr
@@ -0,0 +1,8 @@
+ipv6mon is a tool meant for monitoring IPv6 address usage on a local
+network. It is meant to be particularly useful in networks that employ
+IPv6 Stateless Address Auto-Configuration (as opposed to DHCPv6),
+where address assignment is decentralized and there is no central
+server that records which IPv6 addresses have been assigned to which
+nodes during which period of time.
+
+WWW: http://www.si6networks.com/tools/ipv6mon/
diff --git a/net-mgmt/ipv6mon/pkg-plist b/net-mgmt/ipv6mon/pkg-plist
new file mode 100644
index 000000000000..cfecc4da24c2
--- /dev/null
+++ b/net-mgmt/ipv6mon/pkg-plist
@@ -0,0 +1,5 @@
+@comment $FreeBSD$
+@unexec cmp -s %D/etc/ipv6mon.conf.dist %D/etc/ipv6mon.conf && rm -f %D/etc/ipv6mon.conf || true
+etc/ipv6mon.conf.dist
+@exec if [ ! -r %D/etc/ipv6mon.conf ]; then install -m 444 %D/etc/ipv6mon.conf.dist %D/etc/ipv6mon.conf; fi
+sbin/ipv6mon