From 51193a79fa88f5eab19efb25824fd86408698657 Mon Sep 17 00:00:00 2001 From: Thilo Bangert Date: Fri, 28 Jun 2002 11:54:12 +0000 Subject: moving 13 packages from net-misc to net-analyzer - import --- net-analyzer/portsentry/ChangeLog | 16 +++++++ .../portsentry/files/digest-portsentry-1.1-r6 | 1 + net-analyzer/portsentry/files/portsentry.confd | 3 ++ net-analyzer/portsentry/files/portsentry.rc6 | 40 +++++++++++++++++ net-analyzer/portsentry/portsentry-1.1-r6.ebuild | 52 ++++++++++++++++++++++ 5 files changed, 112 insertions(+) create mode 100644 net-analyzer/portsentry/ChangeLog create mode 100644 net-analyzer/portsentry/files/digest-portsentry-1.1-r6 create mode 100644 net-analyzer/portsentry/files/portsentry.confd create mode 100644 net-analyzer/portsentry/files/portsentry.rc6 create mode 100644 net-analyzer/portsentry/portsentry-1.1-r6.ebuild (limited to 'net-analyzer/portsentry') diff --git a/net-analyzer/portsentry/ChangeLog b/net-analyzer/portsentry/ChangeLog new file mode 100644 index 000000000000..8d87e373997b --- /dev/null +++ b/net-analyzer/portsentry/ChangeLog @@ -0,0 +1,16 @@ +# ChangeLog for net-analyzer/portsentry +# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/portsentry/ChangeLog,v 1.1 2002/06/28 11:54:12 bangert Exp $ + + 28 Jun 2002; Thilo Bangert : + moved to net-analyzer - added SLOT - added LICENSE + +*portsentry-1.1-r6 (1 Feb 2002) + + 1 Feb 2002; G.Bevin ChangeLog : + + Added initial ChangeLog which should be updated whenever the package is + updated in any way. This changelog is targetted to users. This means that the + comments should well explained and written in clean English. The details about + writing correct changelogs are explained in the skel.ChangeLog file which you + can find in the root directory of the portage repository. diff --git a/net-analyzer/portsentry/files/digest-portsentry-1.1-r6 b/net-analyzer/portsentry/files/digest-portsentry-1.1-r6 new file mode 100644 index 000000000000..ef450b8e157a --- /dev/null +++ b/net-analyzer/portsentry/files/digest-portsentry-1.1-r6 @@ -0,0 +1 @@ +MD5 782839446b7eca554bb1880ef0882670 portsentry-1.1.tar.gz 45871 diff --git a/net-analyzer/portsentry/files/portsentry.confd b/net-analyzer/portsentry/files/portsentry.confd new file mode 100644 index 000000000000..38f8969166d0 --- /dev/null +++ b/net-analyzer/portsentry/files/portsentry.confd @@ -0,0 +1,3 @@ +# Config file for /etc/init.d/portsentry + +#PORTSENTRY_MODES="udp tcp stcp atcp sudp audp diff --git a/net-analyzer/portsentry/files/portsentry.rc6 b/net-analyzer/portsentry/files/portsentry.rc6 new file mode 100644 index 000000000000..ccf2fccdbd67 --- /dev/null +++ b/net-analyzer/portsentry/files/portsentry.rc6 @@ -0,0 +1,40 @@ +#!/sbin/runscript +# Copyright 1999-2002 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License, v2 or later +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/portsentry/files/portsentry.rc6,v 1.1 2002/06/28 11:54:12 bangert Exp $ + +# NB: Config is in /etc/conf.d/portsentry + + +depend() { + need net +} + +checkconfig() { + if [ ! -e /etc/portsentry/portsentry.conf ] ; then + eerror "You need an /etc/portsentry/portsentry.conf file" + eerror "There is a sample in /usr/share/doc/portsentry" + return 1 + fi + if [ -z "$PORTSENTRY_MODES" ] ; then + eerror "You need to setup your PORTSENTRY_MODES first" + eerror "Check /etc/conf.d/portsentry that you've enabled some or all of them" + return 1 + fi +} + +start() { + checkconfig || return 1 + ebegin "Starting portsentry" + for mode in $PORTSENTRY_MODES ; do + /usr/bin/portsentry -$mode + result=$(( $result + $? )) + done + eend $result +} + +stop() { + ebegin "Stopping portsentry" + killall portsentry + eend $? +} diff --git a/net-analyzer/portsentry/portsentry-1.1-r6.ebuild b/net-analyzer/portsentry/portsentry-1.1-r6.ebuild new file mode 100644 index 000000000000..f745bd08d6f2 --- /dev/null +++ b/net-analyzer/portsentry/portsentry-1.1-r6.ebuild @@ -0,0 +1,52 @@ +# Copyright 1999-2001 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License, v2 or later +# Author Ben Lutgens +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/portsentry/portsentry-1.1-r6.ebuild,v 1.1 2002/06/28 11:54:12 bangert Exp $ + +DESCRIPTION="Automated port scan detector and response tool" +HOMEPAGE="http://www.psionic.com/abacus/portsentry/" + +SRC_URI="http://www.psionic.com/tools/${P}.tar.gz" +S=${WORKDIR}/${P} +SLOT="0" +LICENSE="GPL-2" + +DEPEND="virtual/glibc" + +src_unpack() { + + unpack ${A} ; cd ${S} + + # Setting the portsentry.conf file location + sed -e 's:/usr/local/psionic/portsentry/portsentry.conf:/etc/portsentry/portsentry.conf:' \ + portsentry_config.h | cat > portsentry_config.h + + # presetting the other file locations in portsentry.conf + sed -e 's:^IGNORE_FILE.*:IGNORE_FILE="/etc/portsentry/portsentry.ignore":g' \ + -e 's:^HISTORY_FILE.*:HISTORY_FILE="/etc/portsentry/portsentry.history":g' \ + -e 's:^BLOCKED_FILE.*:BLOCKED_FILE="/etc/portsentry/portsentry.blocked":g' \ + portsentry.conf | cat > portsentry.conf + + sed -e "s:^set SENTRYDIR.*:set SENTRYDIR=/etc/portsentry:g" \ + ignore.csh | cat > ignore.csh +} + +src_compile() { + + make CFLAGS="${CFLAGS}" linux || die +} + +src_install () { + + dobin portsentry ignore.csh + dodoc README* CHANGES LICENSE CREDITS + newdoc portsentry.ignore portsentry.ignore.sample + newdoc portsentry.conf portsentry.conf.sample + + insinto /etc/portsentry + newins portsentry.ignore portsentry.ignore.sample + newins portsentry.conf portsentry.conf.sample + + exeinto /etc/init.d ; newexe ${FILESDIR}/portsentry.rc6 portsentry + insinto /etc/conf.d ; newins ${FILESDIR}/portsentry.confd portsentry +} -- cgit v1.2.3-65-gdbad