aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipaudit
diff options
context:
space:
mode:
authorkrion <krion@FreeBSD.org>2003-07-23 16:49:01 +0800
committerkrion <krion@FreeBSD.org>2003-07-23 16:49:01 +0800
commit7a5720a5caf3a74cd1e7abbda96f738224e17c61 (patch)
treec6492c0224454c01f07be66d0237af718d2e22b6 /net/ipaudit
parent3357ca11d8d29278353cd7e75fcca83c74ebd92f (diff)
downloadfreebsd-ports-gnome-7a5720a5caf3a74cd1e7abbda96f738224e17c61.tar.gz
freebsd-ports-gnome-7a5720a5caf3a74cd1e7abbda96f738224e17c61.tar.zst
freebsd-ports-gnome-7a5720a5caf3a74cd1e7abbda96f738224e17c61.zip
Port added with slight modification
PR: 54510 Submitted by: Ying-Chieh Chen <yinjieh@csie.nctu.edu.tw> Approved by: fjoe (mentor) (implicit)
Diffstat (limited to 'net/ipaudit')
-rw-r--r--net/ipaudit/Makefile41
-rw-r--r--net/ipaudit/distinfo1
-rw-r--r--net/ipaudit/files/patch-Makefile15
-rw-r--r--net/ipaudit/files/patch-src::Makefile50
-rw-r--r--net/ipaudit/files/patch-src::hash.h11
-rw-r--r--net/ipaudit/pkg-descr21
-rw-r--r--net/ipaudit/pkg-message11
-rw-r--r--net/ipaudit/pkg-plist6
8 files changed, 156 insertions, 0 deletions
diff --git a/net/ipaudit/Makefile b/net/ipaudit/Makefile
new file mode 100644
index 000000000000..85181ae68372
--- /dev/null
+++ b/net/ipaudit/Makefile
@@ -0,0 +1,41 @@
+# New ports collection makefile for: ipaudit
+# Date created: 15 July 2003
+# Whom: Ying-Chieh Chen <yinjieh@csie.nctu.edu.tw>
+#
+# $FreeBSD$
+#
+
+PORTNAME= ipaudit
+PORTVERSION= 0.95
+CATEGORIES= net sysutils
+MASTER_SITES= http://ipaudit.sourceforge.net/download/
+EXTRACT_SUFX= .tgz
+
+MAINTAINER= yinjieh@csie.nctu.edu.tw
+COMMENT= IP traffic summarizer
+
+MAN1= ipaudit.1 ipstrings.1 total.1
+
+BIN= ipaudit ipstrings total
+
+MSG_FILE= ${PKGDIR}/pkg-message
+PKGMESSAGE= ${WRKDIR}/pkg-message
+
+do-install:
+.for b in ${BIN}
+ cd ${WRKSRC}/src && ${INSTALL_PROGRAM} $b ${PREFIX}/bin
+.endfor
+.for m in ${MAN1}
+ cd ${WRKSRC}/man/man1 && ${INSTALL_MAN} $m ${PREFIX}/man/man1
+.endfor
+ cd ${WRKSRC}/src && ${INSTALL_DATA} ipaudit.conf.sample ${PREFIX}/etc
+
+post-install:
+.if !defined(NOPORTDOCS)
+ ${MKDIR} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+.endif
+ @${SED} 's|%%PREFIX%%|${PREFIX}|g' ${MSG_FILE} > ${PKGMESSAGE}
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.mk>
diff --git a/net/ipaudit/distinfo b/net/ipaudit/distinfo
new file mode 100644
index 000000000000..5f885bd5239e
--- /dev/null
+++ b/net/ipaudit/distinfo
@@ -0,0 +1 @@
+MD5 (ipaudit-0.95.tgz) = 8581ea00ebb854806b19a3759764f536
diff --git a/net/ipaudit/files/patch-Makefile b/net/ipaudit/files/patch-Makefile
new file mode 100644
index 000000000000..3e4aa81735ce
--- /dev/null
+++ b/net/ipaudit/files/patch-Makefile
@@ -0,0 +1,15 @@
+--- Makefile.orig Wed Oct 18 01:38:27 2000
++++ Makefile Tue Jul 15 18:20:49 2003
+@@ -8,10 +8,10 @@
+ BIN=ipaudit ipstrings total pdate
+
+ MAKE=make
+-CIDIR=-I/usr/include/pcap
++#CIDIR=-I/usr/include/pcap
+
+ all:
+- $(MAKE) -C src all
++ cd src && $(MAKE) all
+
+ clean:
+ $(MAKE) -C src clean
diff --git a/net/ipaudit/files/patch-src::Makefile b/net/ipaudit/files/patch-src::Makefile
new file mode 100644
index 000000000000..7024a9dec573
--- /dev/null
+++ b/net/ipaudit/files/patch-src::Makefile
@@ -0,0 +1,50 @@
+--- src/Makefile.orig Mon Jan 8 05:56:59 2001
++++ src/Makefile Tue Jul 15 18:19:58 2003
+@@ -1,36 +1,36 @@
+-CIDIR=-I/usr/include/pcap
++#CIDIR=-I/usr/include/pcap
+
+ #LIB=../../libpcap-0.5/libpcap.a
+ LIB=-lpcap
+
+-all: ipaudit total ipstrings beta-dir
++all: ipaudit total ipstrings
+
+ ipaudit: ipaudit.o hash.o
+- $(CC) -o ipaudit ipaudit.o hash.o $(LIB)
++ $(CC) $(CFLAGS) -o ipaudit ipaudit.o hash.o $(LIB)
+
+ total: total.o hash.o
+- $(CC) -o total total.o hash.o -lm
++ $(CC) $(CFLAGS) -o total total.o hash.o -lm
+
+ ipstrings: ipstrings.o
+- $(CC) -o ipstrings ipstrings.o $(LIB)
++ $(CC) $(CFLAGS) -o ipstrings ipstrings.o $(LIB)
+
+ ipaudit.o: ipaudit.c hash.h
+- $(CC) -c ipaudit.c $(CIDIR) $(DFLAGS)
++ $(CC) $(CFLAGS) -c ipaudit.c $(CIDIR) $(DFLAGS)
+
+ hash.o: hash.c hash.h
+- $(CC) -c hash.c
++ $(CC) $(CFLAGS) -c hash.c
+
+ total.o: total.c hash.c hash.h
+- $(CC) -c total.c
++ $(CC) $(CFLAGS) -c total.c
+
+ ipstrings.o: ipstrings.c
+- $(CC) -c ipstrings.c $(CIDIR) $(DFLAGS)
++ $(CC) $(CFLAGS) -c ipstrings.c $(CIDIR) $(DFLAGS)
+
+ iprange: iprange.c
+ $(CC) -g -o iprange iprange.c
+
+-beta-dir:
+- $(MAKE) -C beta
++#beta-dir:
++# $(MAKE) -C beta
+
+ clean:
+ rm -f *.o
diff --git a/net/ipaudit/files/patch-src::hash.h b/net/ipaudit/files/patch-src::hash.h
new file mode 100644
index 000000000000..ed2cf54dd670
--- /dev/null
+++ b/net/ipaudit/files/patch-src::hash.h
@@ -0,0 +1,11 @@
+--- src/hash.h.orig Tue Jul 15 16:53:16 2003
++++ src/hash.h Tue Jul 15 16:53:49 2003
+@@ -1,6 +1,8 @@
+ #ifndef _HASH_H
+ #define _HASH_H
+
++#include <sys/types.h>
++
+ /*
+ ------------------------------------------------------------------------
+ Type Definitions
diff --git a/net/ipaudit/pkg-descr b/net/ipaudit/pkg-descr
new file mode 100644
index 000000000000..0c8f53e42059
--- /dev/null
+++ b/net/ipaudit/pkg-descr
@@ -0,0 +1,21 @@
+Would you like to summarize and/or log network activity down to the ip address
+and port level of detail, but not record every packet?
+
+Ipaudit provides that ability.
+
+Ipaudit listens to a network device in promiscuous mode, and records of every
+'connection', each conversation between two ip addresses. A unique connection
+is determined by the ip addresses of the two machines, the protocol used
+between them and the port numbers (if they are communicating via udp or tcp).
+
+It uses a hash table to keep track of the number of bytes and packets in both
+directions. When ipaudit receives a signal SIGTERM (kill) or SIGINT (kill -2,
+usually the same as a Control-C), it stops collecting data and writes the
+tabulated results.
+
+Ipaudit is built using the pcap packet capture library to read the network port
+from LBNL Network Research Group.
+
+WWW: http://ipaudit.sourceforge.net/
+
+Maintainer: "Ying-Chieh Chen" <yinjieh@csie.nctu.edu.tw>
diff --git a/net/ipaudit/pkg-message b/net/ipaudit/pkg-message
new file mode 100644
index 000000000000..c514dad84682
--- /dev/null
+++ b/net/ipaudit/pkg-message
@@ -0,0 +1,11 @@
+***********************************************************
+
+ Please copy %%PREFIX%%/etc/ipaudit.conf.sample to
+ %%PREFIX%%/ipaudit.conf by yourself and modify it,
+ then start ipaudit with
+
+ 'ipaudit -g /usr/local/etc/ipaudit.conf' command.
+
+ Thanks.
+
+***********************************************************
diff --git a/net/ipaudit/pkg-plist b/net/ipaudit/pkg-plist
new file mode 100644
index 000000000000..80403c68db4a
--- /dev/null
+++ b/net/ipaudit/pkg-plist
@@ -0,0 +1,6 @@
+bin/ipaudit
+bin/ipstrings
+bin/total
+etc/ipaudit.conf.sample
+%%PORTDOCS%%%%DOCSDIR%%/README
+%%PORTDOCS%%@dirrm %%DOCSDIR%%