summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /net-analyzer/nsat
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'net-analyzer/nsat')
-rw-r--r--net-analyzer/nsat/Manifest1
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch33
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-configure.patch25
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-lvalue-gcc4.patch11
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-misc.patch108
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-strip.patch10
-rw-r--r--net-analyzer/nsat/files/nsat-1.5-va_list.patch27
-rw-r--r--net-analyzer/nsat/metadata.xml9
-rw-r--r--net-analyzer/nsat/nsat-1.5-r3.ebuild70
9 files changed, 294 insertions, 0 deletions
diff --git a/net-analyzer/nsat/Manifest b/net-analyzer/nsat/Manifest
new file mode 100644
index 000000000000..a800ee0cc2e1
--- /dev/null
+++ b/net-analyzer/nsat/Manifest
@@ -0,0 +1 @@
+DIST nsat-1.5.tgz 410603 SHA256 2ece807b3240a6e91ea88fd84c470a87de711c33554b231e071549388cb65114 SHA512 1a5b8e88f7bcacdbe1144a719a2e446c0ea025ad4e5f8c79ccb939083308cd2c1b2c1f3d7ab3b791924d5855994cbc3fded95aa36df23c12fd76fc20341a87d0 WHIRLPOOL 52cd94b75668bb3b7342090ec1ec9949b1e9324aabff4a0b03b251c0933829cd63eeb53877c463b282806896099ccbacaa01c390ef61c4b24e8c6d8e356fb5ff
diff --git a/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch b/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch
new file mode 100644
index 000000000000..883ad26cdfaf
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-amd64-compat.patch
@@ -0,0 +1,33 @@
+--- a/src/mod/xp_icmp_echo.c
++++ b/src/mod/xp_icmp_echo.c
+@@ -90,7 +90,7 @@
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+
+- recv_pack = read_icmp(&res, ICMP_ECHOREPLY, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_ECHOREPLY, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
+--- a/src/mod/xp_icmp_infr.c
++++ b/src/mod/xp_icmp_infr.c
+@@ -83,7 +83,7 @@
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+
+- recv_pack = read_icmp(&res, ICMP_IREQREPLY, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_IREQREPLY, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
+--- a/src/mod/xp_udp_probe.c
++++ b/src/mod/xp_udp_probe.c
+@@ -92,7 +92,7 @@
+ #ifdef EBUG
+ fprintf(stderr,"[%d bytes] sent, waiting for reponse.\n", res);
+ #endif
+- recv_pack = read_icmp(&res, ICMP_UNREACH, -1);
++ recv_pack = read_icmp((ssize_t *)&res, ICMP_UNREACH, -1);
+
+ if (recv_pack == NULL || (unsigned)res < sizeof(ip) + 8) {
+ #ifdef EBUG
diff --git a/net-analyzer/nsat/files/nsat-1.5-configure.patch b/net-analyzer/nsat/files/nsat-1.5-configure.patch
new file mode 100644
index 000000000000..d1bc1f95e6bb
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-configure.patch
@@ -0,0 +1,25 @@
+--- a/configure.in
++++ b/configure.in
+@@ -15,7 +15,6 @@
+ else
+ AC_MSG_RESULT(crappy :P)
+ fi
+- LEETCC=$ac_cv_prog_gcc;
+ AC_PROG_CXX
+ AC_PROG_INSTALL
+ AC_PROG_MAKE_SET
+@@ -45,11 +44,11 @@
+ if test $LEETCC = yes; then
+ CCOPTS='-Wall -O6 -funroll-loops -ansi -fPIC -DLINUX'
+ else
+- CCOPTS='-DLINUX'
++ CCOPTS="${CFLAGS} -DLINUX"
+ fi
+- CFLAGS="$CCOPTS"
+- SMBCFLAGS="-Wall -DLINUX -DNETGROUP -DALLOW_CHANGE_PASSWORD -DFAST_SHARE_MODES -DNO_ASMSIGNALH -DGLIBC2"
++ SMBCFLAGS="${CCOPTS} -Wall -DLINUX -DNETGROUP -DALLOW_CHANGE_PASSWORD -DFAST_SHARE_MODES -DNO_ASMSIGNALH -DGLIBC2"
+ SMBLFLAGS="-lnsl -lcrypt"
++ CFLAGS="${CCOPTS} -Wall -ansi -fPIC -DLINUX"
+ ;;
+ *Darwin* | *Mac* | *MAC*)
+ AC_MSG_RESULT(found MAC OS X)
diff --git a/net-analyzer/nsat/files/nsat-1.5-lvalue-gcc4.patch b/net-analyzer/nsat/files/nsat-1.5-lvalue-gcc4.patch
new file mode 100644
index 000000000000..b4020b3f47ed
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-lvalue-gcc4.patch
@@ -0,0 +1,11 @@
+--- a/src/smb/ADMsmb.c
++++ b/src/smb/ADMsmb.c
+@@ -123,7 +123,7 @@
+ {
+ usleep (100000);
+
+- if (recvfrom (socket_client, buffer2, sizeof (buffer2), 0, (struct sockaddr *) &sin_dst, &(int) longueur) != -1)
++ if (recvfrom (socket_client, buffer2, sizeof (buffer2), 0, (struct sockaddr *) &sin_dst, (int *) &longueur) != -1)
+ {
+
+ if (nmb2->rep_num != 0)
diff --git a/net-analyzer/nsat/files/nsat-1.5-misc.patch b/net-analyzer/nsat/files/nsat-1.5-misc.patch
new file mode 100644
index 000000000000..f94fd24527b5
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-misc.patch
@@ -0,0 +1,108 @@
+* link against dev-libs/libmix
+* parallel $(MAKE)
+* usr/local/ -> usr/
+* LDFLAGS
+* verbose CC
+
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -7,14 +7,14 @@
+ # # #### # # #
+
+ # Change me if you want...
+-INSTALL_PATH=/usr/local/bin
+-MAN_PATH=/usr/local/man
++INSTALL_PATH=/usr/bin
++MAN_PATH=/usr/man
+
+ # If you change this, change src/lang.h as well
+-DATA_PATH=/usr/local/share/nsat
++DATA_PATH=/usr/share/nsat
+
+ all:
+- @cd src;make all
++ @cd src; $(MAKE) all
+ @echo ""
+ @echo " Compiling is done!"
+ @echo " You can now 'make install' to put the files in place."
+@@ -58,5 +58,5 @@
+ doc/nsat.8:
+ @echo "Hmm, can't find manpage -- skipping :/"
+
+-nsat:
+- @make all
++nsat: src
++ $(MAKE) all
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -21,22 +21,22 @@
+
+ MIXOBJ = libmix++/net/net.o libmix++/misc/misc.o libmix++/misc/exclude.o
+
+-all: ../smb-ns $(OBJ) modobj mixobj ../nsat
++all: ../smb-ns $(OBJ) modobj ../nsat
+
+ ../smb-ns:
+- @cd smb ; make smb
++ @cd smb ; $(MAKE) smb
+
+-mixobj: libmix++/Makefile
+- @cd libmix++ ; make
++#mixobj: libmix++/Makefile
++# @cd libmix++ ; $(MAKE)
+
+-libmix++/Makefile:
+- @cd .. ; ./configure
++#libmix++/Makefile:
++# @cd .. ; ./configure
+
+ modobj:
+- @cd mod ; make modobj
++ @cd mod ; $(MAKE) modobj
+
+-../nsat:
+- ${GPP} ${CFLAGS} ${OBJ} ${MODOBJ} ${MIXOBJ} -o ../nsat ${CLIB}
++../nsat: modobj
++ ${GPP} ${CFLAGS} ${LDFLAGS} ${OBJ} ${MODOBJ} ${MIXOBJ} -o ../nsat ${CLIB}
+
+ pidalloc.o:
+ ${GPP} ${CFLAGS} -c pidalloc.cpp
+@@ -63,11 +63,11 @@
+ ${GPP} ${CFLAGS} -c Logging.cpp
+
+ clean:
+- cd mod && make clean
++ cd mod && $(MAKE) clean
+ rm -f core *.o ../*.log *.log *~ ../nsat ../.nsrc ../.nspid
+
+ distclean: clean
+- @cd mod ; make clean
+- @cd smb ; make clean
+- @cd libmix++ ; make clean
++ @cd mod ; $(MAKE) clean
++ @cd smb ; $(MAKE) clean
++ @cd libmix++ ; $(MAKE) clean
+ rm -f mod/Makefile Makefile
+--- a/src/smb/Makefile.in
++++ b/src/smb/Makefile.in
+@@ -11,7 +11,6 @@
+ LIBDIR = $(BASEDIR)/lib
+ VARDIR = $(BASEDIR)/var
+ INSTALLPERMS = 0755
+-FLAGS1 = -O3
+ LIBS1 =
+ SHELL = /bin/sh
+ srcdir = ./
+@@ -53,10 +52,10 @@
+ .SUFFIXES: .c .o .h
+
+ .c.o: $(INCLUDES)
+- @$(CC) $(CFLAGS) -c $(srcdir)$*.c -o $(srcdir)$*.o
++ $(CC) $(CFLAGS) $(LDFLAGS) -c $(srcdir)$*.c -o $(srcdir)$*.o
+
+ smb: msg $(CLIENT_OBJ) $(ARCFOUR_OBJ)
+- @$(CC) $(CFLAGS) -o $(BINARY) $(CLIENT_OBJ) $(ARCFOUR_OBJ) $(LIBS)
++ $(CC) $(CFLAGS) $(LDFLAGS) -o $(BINARY) $(CLIENT_OBJ) $(ARCFOUR_OBJ) $(LIBS)
+ @echo done
+
+ msg:
diff --git a/net-analyzer/nsat/files/nsat-1.5-strip.patch b/net-analyzer/nsat/files/nsat-1.5-strip.patch
new file mode 100644
index 000000000000..99fe77633ad8
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-strip.patch
@@ -0,0 +1,10 @@
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -37,7 +37,6 @@
+
+ ../nsat:
+ ${GPP} ${CFLAGS} ${OBJ} ${MODOBJ} ${MIXOBJ} -o ../nsat ${CLIB}
+- strip ../nsat
+
+ pidalloc.o:
+ ${GPP} ${CFLAGS} -c pidalloc.cpp
diff --git a/net-analyzer/nsat/files/nsat-1.5-va_list.patch b/net-analyzer/nsat/files/nsat-1.5-va_list.patch
new file mode 100644
index 000000000000..46bdd3bcc121
--- /dev/null
+++ b/net-analyzer/nsat/files/nsat-1.5-va_list.patch
@@ -0,0 +1,27 @@
+--- a/src/Logging.cpp
++++ b/src/Logging.cpp
+@@ -89,16 +89,17 @@
+ if((pi.Foreground) && (out!=NULL))
+ fprintf(stdout, "%s %s ", out, hn);
+
+- va_start(va, fmt);
+-
+- if(fp!=NULL)
++ if(fp!=NULL) {
++ va_start(va, fmt);
+ vfprintf(fp, fmt, va);
++ va_end(va);
++ }
+
+- if((pi.Foreground) && (out!=NULL))
++ if((pi.Foreground) && (out!=NULL)) {
++ va_start(va, fmt);
+ vfprintf(stdout, fmt, va);
+-
+- va_end(va);
+-
++ va_end(va);
++ }
+ if(fp!=NULL)
+ fprintf(fp, "\n");
+
diff --git a/net-analyzer/nsat/metadata.xml b/net-analyzer/nsat/metadata.xml
new file mode 100644
index 000000000000..e98921b44b4f
--- /dev/null
+++ b/net-analyzer/nsat/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>netmon</herd>
+ <longdescription>Network Security Analysis Tool, an application-level network security scanner</longdescription>
+ <upstream>
+ <remote-id type="sourceforge">nsat</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/net-analyzer/nsat/nsat-1.5-r3.ebuild b/net-analyzer/nsat/nsat-1.5-r3.ebuild
new file mode 100644
index 000000000000..03ce4e5bfaec
--- /dev/null
+++ b/net-analyzer/nsat/nsat-1.5-r3.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+inherit autotools eutils toolchain-funcs
+
+DESCRIPTION="Network Security Analysis Tool, an application-level network security scanner"
+HOMEPAGE="http://nsat.sourceforge.net/"
+SRC_URI="mirror://sourceforge/nsat/${P}.tgz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc x86"
+IUSE="X"
+
+RDEPEND="
+ X? (
+ x11-libs/libX11
+ dev-lang/tk
+ )
+ dev-libs/libmix
+ net-libs/libpcap
+"
+DEPEND="$RDEPEND"
+
+S="${WORKDIR}/${PN}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-configure.patch
+ epatch "${FILESDIR}"/${P}-lvalue-gcc4.patch
+ epatch "${FILESDIR}"/${P}-strip.patch
+ epatch "${FILESDIR}"/${P}-misc.patch
+ epatch "${FILESDIR}"/${P}-va_list.patch
+ use amd64 && epatch "${FILESDIR}"/${P}-amd64-compat.patch
+
+ sed -i \
+ -e "s:^#CGIFile /usr/local/share/nsat/nsat.cgi$:#CGIFile /usr/share/nsat/nsat.cgi:g" \
+ nsat.conf || die
+ sed -i -e "s:/usr/local:/usr:g" tools/xnsat || die
+ sed -i \
+ -e "s:/usr/local/share/nsat/nsat.conf:/etc/nsat/nsat.conf:g" \
+ -e "s:/usr/local/share/nsat/nsat.cgi:/usr/share/nsat/nsat.cgi:g" \
+ src/lang.h || die
+
+ eautoreconf
+}
+
+src_configure() {
+ tc-export CC
+ econf $(use_with X x)
+}
+
+src_compile() {
+ emake MIXOBJ=-lmix++
+}
+
+src_install () {
+ dobin nsat smb-ns
+ use X && dobin tools/xnsat
+
+ insinto /usr/share/nsat
+ doins nsat.cgi
+
+ insinto /etc/nsat
+ doins nsat.conf
+
+ dodoc README doc/CHANGES
+ doman doc/nsat.8
+}